diff --git a/lib/personal_plugin_generator/engine.rb b/lib/personal_plugin_generator/engine.rb index 38425a1..bd979a7 100644 --- a/lib/personal_plugin_generator/engine.rb +++ b/lib/personal_plugin_generator/engine.rb @@ -52,6 +52,7 @@ module PersonalPluginGenerator end git = 'git_1.9.1/usr/bin/git' end + %x(cd #{ENV['PWD']} && #{git} fetch origin) @branch = %x(cd #{ENV['PWD']} && #{git} rev-parse --abbrev-ref HEAD).gsub("\n","") new_commit_id = %x(cd #{ENV['PWD']} && #{git} log #{@branch}..origin/#{@branch} --pretty=format:"%H") new_updates = %x(cd #{ENV['PWD']} && #{git} log #{@branch}..origin/#{@branch} --pretty=format:"%ad' , '%s" --date=short).split("\n").map{|log| log.gsub("'","")}