Monday, August 27, 2012

Getting Jekyll installed on Debian Squeeze

I've been trying to learn Jekyll to build my personal site on GitHub.  Getting it setup on Debian proved to be more difficult than I expected.

Installing Ruby was easy.  It didn't install the gem package manager so I needed to add it separately.  Save yourself some time and run (as root):


apt-get install ruby rubygems


This also adds the gem installer.

Then run:


gem install jekyll


Now, all the docs related to Jekyll say run:


jekyll --server


And everything will be great.  However, on Debian, it can't find the program. 

Gems seem to not install in (or near) your $PATH.  You have to add /var/lib/gems/X.Y/bin (in my case X.Y == 1.8, replace with what ever version you installed) to your $PATH.  The best place is /etc/profile so all users get it.  You can also symbolic link it to you ~/bin directory since that's in your path too. 

Regardless, the Internet didn't give the answer - I finally found it in a bug report as a bothersome install location.  It was closed as expected behavior (I still find it bothersome). 

So Internet, do your magic and find my post so someone's life might be a little bit easier...