We don’t need to install full XCode any more in mavericks,
just install the command line developer tools via terminal: (doesn’t work anymore, download the install file from here.)
xcode-select --install and follow the instruction.
The new OS X mavericks(10.9.x) ships with Ruby 2.0 already.
Install bundler with:
sudo gem install bundler
I don’t want the Jekyll gems installed into system gem path, So I create a file named
Gemfile under my jekyll blog folder with content:
source 'https://rubygems.org' gem 'github-pages'
bundle install --path vendor/bundle --binstubs. Unfortunately I got the following error:
An error occurred while installing RedCloth (4.2.9), and Bundler cannot continue. Make sure that `gem install RedCloth -v '4.2.9'` succeeds before bundling.
It’s seemed there’s no gcc-4.2 in my
/usr/bin. The simple solution is just:
sudo ln -s /usr/bin/gcc /usr/bin/gcc-4.2.But after that I still got
RedCloth building failed. Finally solved this by using the method in this link.
Remember to add the
exclude option into your
without that, Jekyll will attemp to compile the file under your gem vendor folder.
Don’t push the gem stuffs into your git repo, adding these:
.bundle/ vendor/ bin/ Gemfile.lock
See your blog by execute:
bundle exec jekyll serve --watch.