Windows 8.1 x64. Trying to follow Github.com instructions for gh-pages with jekyll, first time messing with Ruby in quite a while.
Gemfile:
source 'https://rubygems.org'
gem 'github-pages'
bundle install
succeeds
bundle exec jekyll serve
fails: D:/dev/Ruby22/lib/ruby/gems/2.2.0/gems/hitimes-1.2.2-x86-mingw32/lib/hitimes.rb: 37:in```require': cannot load such file -- hitimes/hitimes (LoadError)
After searching the interwebs, I've tried:
gem uni hitimes
gem ins hitimes -v 1.2.1 --platform ruby
Error persists.
gem update --system 2.3.0
Error persists.
Maybe this is an issue with Ruby on Windows?
> ruby -e "require 'hitimes'" -e 'puts Hitimes.measure { sleep 0.1 }'
D:/dev/Ruby22/lib/ruby/site_ruby/2.2.0/rubygems/core_ext/kernel_require.rb:55:in
`require': cannot load such file -- hitimes/hitimes (LoadError)
from D:/dev/Ruby22/lib/ruby/site_ruby/2.2.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from D:/dev/Ruby22/lib/ruby/gems/2.2.0/gems/hitimes-1.2.2-x86-mingw32/lib/hitimes.rb:37:in `rescue in <top (required)>'
from D:/dev/Ruby22/lib/ruby/gems/2.2.0/gems/hitimes-1.2.2-x86-mingw32/lib/hitimes.rb:32:in `<top (required)>'
from D:/dev/Ruby22/lib/ruby/site_ruby/2.2.0/rubygems/core_ext/kernel_require.rb:135:in `require'
from D:/dev/Ruby22/lib/ruby/site_ruby/2.2.0/rubygems/core_ext/kernel_require.rb:135:in `rescue in require'
from D:/dev/Ruby22/lib/ruby/site_ruby/2.2.0/rubygems/core_ext/kernel_require.rb:144:in `require'
from -e:1:in `<main>'
Yeah, this is a problem with your environment, unfortunately. hitimes
has C extensions, which can sometimes not compile properly. Try re-installing the gem. Other than that, we can't be of much help. :(
Thanks parkr. Somehow trying again this morning I was able to find the solution: hitimes simply doesn't support Ruby 2.2 on Windows yet. https://github.com/copiousfreetime/hitimes/issues/40
Downgrading to Ruby 2.1 allows me to run jekyll serve
. I'm leaving this here in case some other lost soul comes across this error (e.g., by following the GitHub pages instructions).
@mgiuffrida you can actually edit our Windows gotchas if you want and add that little note: https://github.com/jekyll/jekyll/blob/master/site/_docs/windows.md
thanks mgiuffrida I've been looking everywhere for this, this is the exact error I got and I'm also running windows 8.1. I remember reading about some windows versions not working with the newest versions of ruby
Going back I reran the problem again. This time with Ruby 2.1.9 environment. Results:
So steps taken: (I run windows 8.1)
Install ruby 2.1.9
Install devkit (you linked it above)
command prompt stuff:
gem install jekyll
gem install github-pages
gem install bundler (this fixed the issue)
jekyll new . (wherever you specify the folder for the site)
jekyll serve
it worked
Most helpful comment
Thanks parkr. Somehow trying again this morning I was able to find the solution: hitimes simply doesn't support Ruby 2.2 on Windows yet. https://github.com/copiousfreetime/hitimes/issues/40
Downgrading to Ruby 2.1 allows me to run
jekyll serve
. I'm leaving this here in case some other lost soul comes across this error (e.g., by following the GitHub pages instructions).