From a92b6993c9ab8acf791f6de50aa55c9b260db52d Mon Sep 17 00:00:00 2001 From: bohung Date: Fri, 23 Jul 2021 16:42:58 +0800 Subject: [PATCH] Fix bug. --- .../personal_patent/index_search1.html.erb | 2 +- personal_patent.gemspec | 23 +++++++++++-------- 2 files changed, 14 insertions(+), 11 deletions(-) diff --git a/modules/personal_patent/index_search1.html.erb b/modules/personal_patent/index_search1.html.erb index 856793b..03eb09f 100644 --- a/modules/personal_patent/index_search1.html.erb +++ b/modules/personal_patent/index_search1.html.erb @@ -23,7 +23,7 @@ $( ".selectbox" ).ready(function() { Clear - +
diff --git a/personal_patent.gemspec b/personal_patent.gemspec index bc908d1..bd98770 100644 --- a/personal_patent.gemspec +++ b/personal_patent.gemspec @@ -2,16 +2,19 @@ $:.push File.expand_path("../lib", __FILE__) # Maintain your gem's version: require "personal_patent/version" -app_path = File.expand_path(__dir__) -template_path = ENV['PWD'] + '/app/templates' -all_template = Dir.glob(template_path+'/*/') -puts 'copying module' -all_template.each do |folder| - if folder.split('/')[-1] != 'mobile' - begin - system ('cp -r '+ app_path + '/modules/ ' + folder) - rescue - puts 'error copy' +bundle_update_flag = ARGV[0]=='update' || ARGV[0]=='install' +if bundle_update_flag + app_path = File.expand_path(__dir__) + template_path = ENV['PWD'] + '/app/templates' + all_template = Dir.glob(template_path+'/*/') + puts 'copying module' + all_template.each do |folder| + if folder.split('/')[-1] != 'mobile' + begin + system ('cp -r '+ app_path + '/modules/ ' + folder) + rescue + puts 'error copy' + end end end end
{{head-title}}