Require plugins from Gemfile :jekyll_plugins group.
This commit is contained in:
parent
519b60d012
commit
b0a7f9c8c9
|
@ -13,6 +13,8 @@ require 'mercenary'
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
Jekyll::PluginManager.require_from_bundler
|
||||||
|
|
||||||
Jekyll::Deprecator.process(ARGV)
|
Jekyll::Deprecator.process(ARGV)
|
||||||
|
|
||||||
Mercenary.program(:jekyll) do |p|
|
Mercenary.program(:jekyll) do |p|
|
||||||
|
|
|
@ -17,7 +17,7 @@ module Jekyll
|
||||||
def conscientious_require
|
def conscientious_require
|
||||||
require_plugin_files
|
require_plugin_files
|
||||||
require_gems
|
require_gems
|
||||||
require_from_bundler
|
self.require_from_bundler
|
||||||
end
|
end
|
||||||
|
|
||||||
# Require each of the gem plugins specified.
|
# Require each of the gem plugins specified.
|
||||||
|
@ -31,10 +31,11 @@ module Jekyll
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
def require_from_bundler
|
def self.require_from_bundler
|
||||||
unless site.safe
|
unless ENV["JEKYLL_NO_BUNDLER_REQUIRE"]
|
||||||
require "bundler/setup"
|
require "bundler/setup"
|
||||||
Bundler.require(:jekyll_plugins)
|
Bundler.require(:jekyll_plugins)
|
||||||
|
ENV["JEKYLL_NO_BUNDLER_REQUIRE"] = true
|
||||||
end
|
end
|
||||||
rescue LoadError
|
rescue LoadError
|
||||||
false
|
false
|
||||||
|
|
Loading…
Reference in New Issue