Fix bug.
This commit is contained in:
parent
455523cb09
commit
8bf121655b
|
@ -76,16 +76,21 @@ if bundle_update_flag
|
|||
require 'nokogiri'
|
||||
rescue ScriptError => e
|
||||
if RUBY_VERSION.to_f <= 2.1
|
||||
system('gem install nokogiri -v 1.7.0.1')
|
||||
nokogiri_version = '1.7.0.1'
|
||||
else
|
||||
system('gem install nokogiri -v 1.8.5')
|
||||
nokogiri_version = '1.8.5'
|
||||
end
|
||||
flag = system("gem install nokogiri -v #{nokogiri_version}")
|
||||
if flag
|
||||
gem_home = ENV["GEM_HOME"]
|
||||
if !gem_home.nil?
|
||||
$LOAD_PATH << "#{gem_home}/gems/nokogiri-1.7.0.1/lib"
|
||||
$LOAD_PATH << "#{gem_home}/extensions/#{RUBY_PLATFORM}/#{RUBY_VERSION}/nokogiri-1.7.0.1"
|
||||
$LOAD_PATH << "#{gem_home}/gems/nokogiri-#{nokogiri_version}/lib"
|
||||
$LOAD_PATH << "#{gem_home}/extensions/#{RUBY_PLATFORM}/#{RUBY_VERSION}/nokogiri-#{nokogiri_version}"
|
||||
require 'nokogiri'
|
||||
end
|
||||
else
|
||||
next
|
||||
end
|
||||
end
|
||||
puts "changing header.html.erb in #{folder}/home/header.html.erb"
|
||||
if folder.split('/')[-1] != 'mobile'
|
||||
|
|
Loading…
Reference in New Issue