books

Transferring domain (from Webio to GoDaddy)

Recently, I purchased new domains at GoDaddy. I decided to transfer my existing domain jj09.net to GoDaddy as well. I thought it would be easy. However, I have never done this before.

Making long story short, here are steps to accomplish the transfer:

  1. Request the current registrar (in my case: Webio) to remove Privacy Protection and Theft Protection
  2. Request the current registrar (in my case: Webio) to give you authinfo code
  3. Start domain transfer at GoDaddy
  4. You should receive Transaction ID and Security code from the current registrar (requested by GoDaddy)
  5. Authorize transfer at GoDaddy using:
    • Transaction ID
    • Security Code
    • Authinfo code

After that it should take around 7 days to perform the transfer. I received e-mail (from current registrar) that the transfer will be performed in a few days if I do not cancel it. It is some sort of theft protection. In your case (if you have different registrar) it may be different. E.g. you may need to confirm the transfer.

The best way is to contact you current registrar and destination registrar about the specific instructions. That’s what I did and both was very nice and helpful.

EDIT: Do not forget to change Nameservers and DNSes on GoDaddy after transfer is completed 😉


A book that every programmer should read: The Elements of Computing Systems

I would like to say thank you to Scott Hanselman, who tweeted about this book. When I saw the content, I knew I will love it. And I was right.

The Elements of Computing Systems cover

The Elements of Computing Systems: Building a Modern Computer from First Principles is written by Noam Nisan and Shimon Schocken, who are University Professors. They created course based on this book (or wrote this book based on their course :)). The first 6 (out of 12) chapters are available for free at course website.

Why every programmer should read this book? Because it allows you to understand how computer works. It is going from logic gates, through machine code, intermediate code, compilers etc., to high level programming language. At the end of each chapter, there are exercises in which you are ‘building’ parts of the computer.

This book has only 344 pages and of course it doesn’t cover all details. Each chapter is kind of basic overview, however it is sufficient to get the idea and basic understanding before you go more deeply (e.g. into Computer Architecture or Compilers).

I really enjoyed reading this book. It is amazing how all those things we are doing everyday on our machines are done just by adding, subtracting, comparing and copying sequences of zeros and ones.

The book is available at amazon. There is also a website with more information about it (e.g. 10 minutes overview video), and software created for exercises (which you can find at the end of each chapter).


Why you should read “The Pragmatic Programmer”

The Pragmatic Programmer cover

Finally I read book written by Andrew Hunt and Dave Thomas: The Pragmatic Programmer. It was published in 1999, but it is still valid. The main idea provided by this book is the way of thinking. In other words: how ‘The Pragmatic Programmer’ should behave and what actions he should take in various situations.

There are also tips which skills are useful for programmer (e.g. using perl/bash scripts, mastering command line and at least one text editor).

Some advices are not valid in any case. E.g. in my opinion tip to never leave broken functionality has exceptions. Especially when it is some minor bug. There are situations when it is better to first focus on most important features and the problematic one leave for the end. After all we will have a few minor bugs and working main functionality. Instead of solved some or even only one, hard minor bug (like css styling:)) and not implemented main functionalities.

The other well-known (or should be well-known) tips like use Source Control, learn new technologies, analyze mistakes from past projects are also mentioned and described.

Here you can find list of tips from the book in nutshell: http://pragprog.com/the-pragmatic-programmer/extracts/tips. It is kind of summary of the book content.

At the and of each chapter, there is a set of exercises. This one blew my mind:

A quick reality check. Which of these “impossible” things can happen?

  1. A month with fewer than 28 days.
  2. stat(“.” ,&sb) == -1 (that is, can’t access the current directory)
  3. In C++: a=2;b=3; if (a+b!=5) exit(l);
  4. A triangle with an interior angle sum != 180°
  5. A minute that doesn’t have 60 seconds
  6. In Java: (a + 1) <= a

Fortunately at the end of the book there are answers (I wouldn’t even start googling, due to 100% certainty that some of them just can not happen, like 1 or 5):

  1. September, 1752 had only 19 days. This was done
    to synchronize calendars as part of the Gregorian
    Reformation.
  2. The directory could have been removed by another
    process, you might not have permission to read it,
    &sb might be invalid—you get the picture.
  3. We sneakily didn’t specify the types of a and b.
    Operator overloading might have defined +, =, or !
    = to have unexpected behavior. Also, a and b may
    be aliases for the same variable, so the second
    assignment will overwrite the value stored in the first.
  4. In non-Euclidean geometry, the sum of the angles of
    a triangle will not add up to 180°. Think of a triangle
    mapped on the surface of a sphere.
  5. Leap minutes may have 61 or 62 seconds.
  6. Overflow may leave the result of a + 1 negative (this
    can also happen in C and C++).

Summarizing: The Pragmatic Programmer contains huge amount of tips, which can help you to become better programmer. You may already know some of them (or most of them). In that case you will recall why they are important. Even Scott Hanselman said on his blog (in post Six Essential Language Agnostic Programming Books), that he ‘like to read this book at least every six months or so’.

It is 352 pages book. Can be easily read within 2 weeks by 1 hour reading per day. In my opinion it is one of must-read for programmer.


The Ten-Day MBA

The Ten-Day MBA cover

Chad Fowler, in his book “The Passionate Programmer” recommended a book The Ten-Day MBA. The reason, why he recommend it, is the fact that successful programmer should know the basics of marketing. E.g. to be aware how much his work is worth.

The Ten-Day MBA is an overview of fundamental basics of economy, business, finance, leadership and even real estate. In my opinion, this book is not only for programmers. It is for everyone! You can find there difference between monetarists and Keynesian economy, the product life cycle (from factory to customer), the difference between corporation and private business, time estimation of projects, business strategies etc.

I strongly recommend this book. I was studying at University of Economics 3 years (Bachelor degree). This book contains all most important concepts I learned there.

You can find it on amazon.


Getting started with Ruby on Rails

Ruby on Rails logo

Recently I decided to learn Ruby on Rails. When you start learning a new technology you are always looking for the best available materials (to learn as efficient as possible). I did the same (using Google and StackOverflow). Fortunately I found The Best Way to Learn Ruby on Rails and I followed the recommended steps. With small modifications (extensions).

First of all I extended first step. Instead of just going through “Try Ruby” exercises I also read first chapter of Seven Languages in Seven Weeks (which is about Ruby). It was very good move, because this book is written in the way to show the flavors of language by comparison with others. I am a .NET guy, who was coding in PHP, C++, Java and Python before. Because of that I was more interested in the differences between Ruby and these languages, than in programming from ground up. I also reviewed (not read) Humble Little Ruby Book. It is a little bit more deep, but it gives you solid Ruby basics.

I was working with Rails on Windows and on Mac. Installing on Windows is very easy when you use RubyInstaller. There is also version for Mac. However on Mac you can also install Rails using RVM. In that case I recommend you installation screncast by Michael Hartl. On Windows I used RubyInstaller, but on Mac I took advantage of Michael Hartl’s screencast. Additionally you may also need SQLite Database Browser to browse your database easily. I did not know about it at the beginning and I was using rails dbconsole. Browsing with SQLite Database Browser is much more comfortable!

When I had Rails installed I went through Jeffrey’s Introduction to Rails. During that I tried to follow him, by writing code on my machine, but many times he was too fast. I needed to pausing video very often and even scrolling back to see written command (he was changing screens to quickly). Anyway it was very nice introduction and I recommend it. But you can skip rewriting and trying code he is writing. Just watch it to get a flavor of Rails.

After that I went through Rails for Zombies tutorials. I was very lucky, because Code School had promotion in May 18-19, and they provided Rails for Zombies 2 for free in these days. These tutorials are very solid. The exercises force you to learn by typing, because you cannot proceed to next level, until you do not finish all tasks.

Agile Web Development with Rails cover

With all basics gained as described above I started a book: Agile Web Development with Rails. I really like this book. It has 3 parts:

  • Getting started (Rails installation, create first app, quick Rails architecture overview)
  • Building application (tutorial)
  • Rails in Depth

The longest part of the book is the tutorial(2nd). Through this part you are creating an complete application exploring different Rails features. Unfortunately this book is a little bit outdated. Authors use ruby version 1.8.7 and Rails 3.0.0. I installed most recent versions: ruby 1.9.3p392 and Rails 3.2.13. Sometimes you need to fix the code (e.g. Chapter 11 – Task F: Add a Dash of Ajax). During that I found Ruby on Rails documentation very useful.

The last part is going deep into Rails. I really recommend this part! It is not only about Rails, but also about Web Applications and MVC architecture in general: how browser works, how requests are handled by Rails app, session, cookies etc.

When I was in the middle of book I was a little bit angry (because it is outdated) and I switched to Ruby on Rails tutorial by Michael Hartl, which is strongly recommended on StackOverflow. Well…guys at SO are right. This is really good piece of knowledge not only about Rails, but also about using git, css, Bootstrap and Web Development in general. I really enjoyed it! If you do not want to buy videos, you can just read the free book (it is the same content as in videos and more). There are also nice videos describing advanced setup for Rails development on Mac and SublimeText configuration for Rails. Actually this tutorial covers Rails development from A to Z.

As a summary to the book and Michael Hartl’s tutorial I reviewed Rails Guides. It is a nice overview for most important rails features. Can be also used as a reference. Some of the RailsCasts are also useful.

I wanted to try a few different tutorials/books to see different approaches. E.g. Michael Hartl use rspec for unit tests, but the authors of Agile Web Development with Rails are using rails testing framework.

My adventure with Ruby (on Rails) lasts almost two months. Now I can admit that ROR is a very powerful and developer friendly framework. It contains many features, which are already grabbed by ASP.NET (e.g. migrations, bundling). What was surprising for me, you do not need IDE to develop Rails apps. I use SublimeText2 (awesome editor!) and it is really enough. Some Rails developers use VIM or Emacs. Of course there are some IDEs such as RubyMine or Aptana Studio. I tried both. RubyMine seems to be pretty cool…but I stick with SublimeText. Additionally, during Rails development you spend lot of time with console (to create/run/undo migrations, create models/controllers, run tests etc.).

If you want to start Rails development, my recommended steps are:

You might also find these tools/resources useful:

What I like in Ruby on Rails? The syntax, convention over configuration and lots of implemented features in the framework layer. Moreover: Rails are just cool.