summaryrefslogtreecommitdiffstats
path: root/lib/redmine/scm/adapters
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2011-04-24 09:55:51 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2011-04-24 09:55:51 +0000
commit92023176b82e83478fcafbc4f17aca4536041114 (patch)
tree1f54e39ba3789ac167f1064604e9fbbb7a6e89c9 /lib/redmine/scm/adapters
parentfb9fed39feb34bfa4a78a654c171bbb5012a4289 (diff)
downloadredmine-92023176b82e83478fcafbc4f17aca4536041114.tar.gz
redmine-92023176b82e83478fcafbc4f17aca4536041114.zip
scm: bazaar: code clean up adapter.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5545 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'lib/redmine/scm/adapters')
-rw-r--r--lib/redmine/scm/adapters/bazaar_adapter.rb7
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/redmine/scm/adapters/bazaar_adapter.rb b/lib/redmine/scm/adapters/bazaar_adapter.rb
index bfa943d7a..1abedeb2e 100644
--- a/lib/redmine/scm/adapters/bazaar_adapter.rb
+++ b/lib/redmine/scm/adapters/bazaar_adapter.rb
@@ -82,8 +82,8 @@ module Redmine
path ||= ''
entries = Entries.new
cmd = "#{self.class.sq_bin} ls -v --show-ids"
- identifier = -1 unless identifier && identifier.to_i > 0
- cmd << " -r#{identifier.to_i}"
+ identifier = -1 unless identifier && identifier.to_i > 0
+ cmd << " -r#{identifier.to_i}"
cmd << " #{target(path)}"
shellout(cmd) do |io|
prefix = "#{url}/#{path}".gsub('\\', '/')
@@ -120,7 +120,6 @@ module Redmine
parsing = nil
else
next unless revision
-
if line =~ /^revno: (\d+)($|\s\[merge\]$)/
revision.identifier = $1.to_i
elsif line =~ /^committer: (.+)$/
@@ -168,7 +167,7 @@ module Redmine
def diff(path, identifier_from, identifier_to=nil)
path ||= ''
if identifier_to
- identifier_to = identifier_to.to_i
+ identifier_to = identifier_to.to_i
else
identifier_to = identifier_from.to_i - 1
end