lib/application.rb in docman-0.0.59 vs lib/application.rb in docman-0.0.60
- old
+ new
@@ -117,10 +117,10 @@
log cmd
path = Dir.pwd
branch = 'commands'
currentBranch = GitUtil.branch
Exec.do "#{Application::bin}/check-branch.sh #{branch}"
- File.open(File.join(path, 'commands'), 'w') {|f| f.write cmd}
+ File.open(File.join(path, 'commands'), 'a') {|f| f.puts cmd}
GitUtil.exec("add commands")
GitUtil.exec("commit -m 'Added command'")
GitUtil.push(path, branch, true)
GitUtil.exec("checkout #{currentBranch}")
end