Articles

Jekyll static site generator

In howto on Dec 30, 2015 by theoryl Tagged: , , ,

Jekyll is probably the most popular static site generator. It allows you to create an entire website using nothing more than Markdown and HTML/CSS. Even better, you can then host the website on GitHub for free. It’s also super easy to set up — see below.

Prerequisites: Ruby, bundler (See my earlier post for Linux Mint 17.3-specific instructions or GitHub Help for general instructions.)

Do bundle init. A file named Gemfile will be created in your current directory. Append gem "github-pages" to the file. Finally, do bundle install. (Don’t run Bundler as root.) You will get a lot of gems:

Fetching gem metadata from https://rubygems.org/............
Fetching version metadata from https://rubygems.org/...
Fetching dependency metadata from https://rubygems.org/..
Resolving dependencies....
Installing RedCloth 4.2.9 with native extensions
Installing i18n 0.7.0
Installing json 1.8.3 with native extensions
Installing minitest 5.8.3
Installing thread_safe 0.3.5
Installing addressable 2.3.8
Installing blankslate 2.1.2.4
Installing fast-stemmer 1.0.2 with native extensions
Installing coffee-script-source 1.10.0
Installing execjs 2.6.0
Installing colorator 0.1
Installing ffi 1.9.10 with native extensions
Installing multipart-post 2.0.0
Installing gemoji 2.1.0
Installing net-dns 0.8.0
Installing public_suffix 1.5.3
Installing jekyll-paginate 1.1.0
Installing sass 3.4.20
Installing rb-fsevent 0.9.7
Installing kramdown 1.9.0
Installing liquid 2.6.2
Installing mercenary 0.3.5
Installing posix-spawn 0.3.11 with native extensions
Installing yajl-ruby 1.2.1 with native extensions
Installing redcarpet 3.3.3 with native extensions
Installing safe_yaml 1.0.4
Installing jekyll-feed 0.3.1
Installing mini_portile2 2.0.0
Installing jekyll-sitemap 0.9.0
Installing maruku 0.7.0
Installing rdiscount 2.1.8 with native extensions
Installing terminal-table 1.5.2
Using bundler 1.11.2
Installing tzinfo 1.2.2
Installing parslet 1.5.0
Installing classifier-reborn 2.0.4
Installing coffee-script 2.4.1
Installing ethon 0.8.0
Installing rb-inotify 0.9.5
Installing faraday 0.9.2
Installing jekyll-sass-converter 1.3.0
Installing pygments.rb 0.6.3
Installing nokogiri 1.6.7.1 with native extensions
Installing activesupport 4.2.5
Installing toml 0.1.2
Installing jekyll-coffeescript 1.0.1
Installing typhoeus 0.8.0
Installing listen 3.0.5
Installing sawyer 0.6.0
Installing html-pipeline 1.9.0
Installing github-pages-health-check 0.5.3
Installing jekyll-watch 1.3.0
Installing octokit 4.2.0
Installing jekyll-gist 1.4.0
Installing jekyll 2.4.0
Installing jekyll-mentions 0.2.1
Installing jekyll-redirect-from 0.8.0
Installing jemoji 0.5.0
Installing github-pages 40
Bundle complete! 1 Gemfile dependency, 59 gems now installed.
Use `bundle show [gemname]` to see where a bundled gem is installed.
Post-install message from html-pipeline:
-------------------------------------------------
Thank you for installing html-pipeline!
You must bundle Filter gem dependencies.
See html-pipeline README.md for more details.
https://github.com/jch/html-pipeline#dependencies
-------------------------------------------------

To create a site:

jekyll new my-awesome-site
cd my-awesome-site
bundle exec jekyll serve --host 127.0.0.1

To keep Jekyll up to date, run:

bundle update
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: