]> source.dussan.org Git - redmine.git/commitdiff
scm: bazaar: add "scm_cmd_no_raise" method for "bzr diff".
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Thu, 26 May 2011 06:15:37 +0000 (06:15 +0000)
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Thu, 26 May 2011 06:15:37 +0000 (06:15 +0000)
"bzr diff" normal exit status is not 0 in Bazaar 2.0.5.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5920 e93f8b46-1217-0410-a6f0-8f06a7374b81

lib/redmine/scm/adapters/bazaar_adapter.rb

index 46877ad43df067e40a0b8c0b5f20f572438351eb..39de200f3631b81ea524f013945d66ae70765fd8 100644 (file)
@@ -281,6 +281,14 @@ module Redmine
         end
         private :scm_cmd
 
+        def scm_cmd_no_raise(*args, &block)
+          full_args = [BZR_BIN]
+          full_args += args
+          ret = shellout(full_args.map { |e| shell_quote e.to_s }.join(' '), &block)
+          ret
+        end
+        private :scm_cmd_no_raise
+
         def bzr_target(path)
           target(path, false)
         end