Skip to content

Instantly share code, notes, and snippets.

@simon-engledew
Created August 25, 2015 14:53
Show Gist options
  • Save simon-engledew/f8d12b95c01c44bb414d to your computer and use it in GitHub Desktop.
Save simon-engledew/f8d12b95c01c44bb414d to your computer and use it in GitHub Desktop.
Building a stand-alone Jekyll for windows
# gem install ocra
# hitimes 1.2.2 does not work on windows, force the pure ruby version
# gem install hitimes --platform ruby
ocra --gem-all --gemfile Gemfile jekyll
source 'https://rubygems.org'
gem 'jekyll'
gem 'wdm', '>= 0.1.0'
gem 'hitimes', :platforms => :ruby # not sure if this works, had to install the pure ruby version manually (see build.sh)
#!c:/Ruby22/bin/ruby.exe
#
# This file was generated by RubyGems.
#
# The application 'jekyll' is installed as part of a gem, and
# this file is here to facilitate running it.
#
# manually require some gems that are not correctly imported
require 'rubygems'
require 'fiber'
gem 'wdm'
require 'webrick'
require 'find'
version = ">= 0"
if ARGV.first
str = ARGV.first
str = str.dup.force_encoding("BINARY") if str.respond_to? :force_encoding
if str =~ /\A_(.*)_\z/ and Gem::Version.correct?($1) then
version = $1
ARGV.shift
end
end
gem 'jekyll', version
load Gem.bin_path('jekyll', 'jekyll', version)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment