This commit is contained in:
bohung committed 2022-10-16 19:55:32 +08:00
1 parent 913e895de9
commit e541d53b3b
6 files changed
+480 -136

No files matched your search

+12 -8
View File
@@ -9,13 +9,13 @@ if bundle_update_flag
template_path = dir_pwd + '/app/templates'
all_template = Dir.glob(template_path+'/*/')
#if !Dir.exist?("#{ENV['PWD']}"+"/app/assets/stylesheets/lib/jquery-ui-1.12.1/")
puts "copying jquery-ui"
begin
`cp -rf "#{app_path}/updatefiles/javascripts/." "#{dir_pwd}/app/assets/javascripts/"`
`cp -r "#{app_path}/updatefiles/accessibility/jquery-ui-1.13.2/." "#{dir_pwd}/app/assets/stylesheets/lib/jquery-ui-1.13.2/"`
rescue
puts "There is an error in coppying jquery-ui"
end
# puts "copying jquery-ui"
# begin
# `cp -rf "#{app_path}/updatefiles/javascripts/." "#{dir_pwd}/app/assets/javascripts/"`
# `cp -r "#{app_path}/updatefiles/accessibility/jquery-ui-1.13.2/." "#{dir_pwd}/app/assets/stylesheets/lib/jquery-ui-1.13.2/"`
# rescue
# puts "There is an error in coppying jquery-ui"
# end
#end
@original_dir = Dir.pwd
`cd "#{dir_pwd}" && git add app/templates/ app/assets built_in_extensions.rb config/mongoid.yml bin/ && cd "#{@original_dir}"` #using git to add modified files and to avoid git pull not working
@@ -75,7 +75,11 @@ if bundle_update_flag
begin
require 'nokogiri'
rescue ScriptError => e
system('gem install nokogiri -v 1.7.0.1')
if RUBY_VERSION.to_f <= 2.1
system('gem install nokogiri -v 1.7.0.1')
else
system('gem install nokogiri -v 1.8.5')
end
gem_home = ENV["GEM_HOME"]
if !gem_home.nil?
$LOAD_PATH << "#{gem_home}/gems/nokogiri-1.7.0.1/lib"