Question

I am trying to create a blog using jekyll. I am using Ubuntu 11.10, but after I installed the ruby gem and try to run it locally on my server i get the following error: /usr/lib/ruby/vendor_ruby/1.8/rubygems.rb:926:in `report_activate_error': Could not find

RubyGem jekyll (>= 0) (Gem::LoadError)
    from /usr/lib/ruby/vendor_ruby/1.8/rubygems.rb:244:in `activate_dep'
    from /usr/lib/ruby/vendor_ruby/1.8/rubygems.rb:236:in `activate'
    from /usr/lib/ruby/vendor_ruby/1.8/rubygems.rb:1307:in `gem'
    from /usr/local/bin/jekyll:18

I think it is a problem with mu ruby gems path. My gem env output is as follows:

RubyGems Environment:
  - RUBYGEMS VERSION: 1.8.24
  - RUBY VERSION: 1.9.3 (2012-02-16 patchlevel 125) [i686-linux]
  - INSTALLATION DIRECTORY: /home/swaroop/.rvm/gems/ruby-1.9.3-p125@test
  - RUBY EXECUTABLE: /home/swaroop/.rvm/rubies/ruby-1.9.3-p125/bin/ruby
  - EXECUTABLE DIRECTORY: /home/swaroop/.rvm/gems/ruby-1.9.3-p125@test/bin
  - RUBYGEMS PLATFORMS:
    - ruby
    - x86-linux
  - GEM PATHS:
     - /home/swaroop/.rvm/gems/ruby-1.9.3-p125@test
     - /home/swaroop/.rvm/gems/ruby-1.9.3-p125@global
  - GEM CONFIGURATION:
     - :update_sources => true
     - :verbose => true
     - :benchmark => false
     - :backtrace => false
     - :bulk_threshold => 1000
  - REMOTE SOURCES:
     - http://rubygems.org/

How do I rectify this?

Was it helpful?

Solution 2

All I had to do was to prefix it with sudo i.e.,

sudo jekyll --server

OTHER TIPS

It's not a good approach to call it with sudo. That it's working with sudo seems like you have not installed the gem under user you are without sudo.

I recommend you

  1. look at https://github.com/plusjade/jekyll-bootstrap.git. It help you with few things.

  2. Start use Bundler ( https://github.com/roolo/roolo.github.com/blob/master/Gemfile ). It will help you to have same version as on Github for future deployment in there.

    • try to clone my blog and then run bundle in dir of the repo
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top