Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Import blog to Jekyll - what is this load error 'require cannot load such file'?

From the related questions that popped up, it looks like I'm missing a dependencey (Ubuntu 16.04). But I have the dependencies listed in the installation guide, and also bundler, because when I tried to set up a new project it gave an error saying that was needed. Once that was installed I ran jekyll new my-site and it set up all the folders and files fine. Then I exported my blog to an xml file, and typed in the command to import it into jekyll:

$ ruby -rubygems -e 'require "jekyll-import";
JekyllImport::Importers::Blogger.run({
"source"        =>"/Downloads/blog-01-18-2017.xml",
})'

But it gave me this error:

/usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot 
load such file -- jekyll-import (LoadError)
    from /usr/lib/ruby/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
    from -e:1:in `<main>'

How can I figure out what dependency is missing? Is there something else I should do?

like image 561
kim holder wants Monica back Avatar asked Jan 18 '17 16:01

kim holder wants Monica back


1 Answers

Before using jekyll-import you need to install it:

$ gem install jekyll-import

Because the importers have many of their own dependencies, they are made available via a separate gem called jekyll-import. To use them, all you need to do is install the gem, and they will become available as part of Jekyll’s standard command line interface.

like image 198
marcanuy Avatar answered Oct 20 '22 00:10

marcanuy