Today I decided to ungrade my Debian 9 instante that was running on my X201 to the testing branch of Debian. This will provide an “rolling” release model for Debian, which means that my applications will always be up to date. Something similar to Fedora, but on the DEB side of Linux.
Thus, installing Ruby and Jekyll is extremely easy in Debian testing, and it would be similar in Debian 9 and perhaps even Ubuntu.

Installation process

In order to install Jekyll in Debian you have to run only a few commands. The fist one will install the latest version of Ruby:

From official repositories As I am using the testing branch, I am having the latest available packages. As a comparison, Debian Testing has the latest 2.5.0 version of Ruby, as Debian 9 Stretch has version 2.3.3 available.

To install them, simply use the command:

sudo apt install ruby-full build-essential

To check the version of Ruby installed, run the command:

on Debian testing

ruby --version
ruby 2.5.0p0 (2017-12-25 revision 61468) [x86_64-linux-gnu]

on Debian 9 Stretch

ruby --version
ruby 2.3.3p222 (2016-11-21) [x86_64-linux-gnu]

Now you can install Jekyll using the gem command of Ruby:

sudo gem install jekyll bundler

That’s it! Much more easier than in CentOS or Fedora. Now lets start using Jekyll.

Using Jekyll

I use Dropbox for my Jekyll project, just to be able to have all the files on all my machines. Thus, I create a new directory for the Jekyll project called jekyll inside my Dropbox:

cd /home/user/Dropbox
mkdir jekyll
cd jekyll

While inside the project’s directory, you must create a new project (which I will call lark) with the command:

jekyll new lark
cd lark/

While inside the new lark directory, run the command:

bundle install

After you create some content (help can be found on the official Jekyll docs site) you can run the local server and test your output with the command:

bundle exec jekyll serve

and then open a browser and point it to the address: http://localhost:4000

There you go! You are now ready to use Jekyll as your Static Site Generator on your Debian machine. Please notice that all of the above commands were executed without root or sudo, unless noted as such.