Merge pull request #1 from varkoly/master

Initial version
Merge pull request #2 from varkoly/master

Follow the instructions of Ladislav Slezák
Adapt ruby coding style