]> source.dussan.org Git - redmine.git/commitdiff
scm: bazaar: use log encoding as path encoding (#11834)
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Tue, 18 Sep 2012 09:30:11 +0000 (09:30 +0000)
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>
Tue, 18 Sep 2012 09:30:11 +0000 (09:30 +0000)
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10420 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/models/repository/bazaar.rb
lib/redmine/scm/adapters/bazaar_adapter.rb

index db05e673b418b604685409b5aa87f3e584429f53..6dcf963d98a474e53c1b04f39216adae242a7b93 100644 (file)
@@ -37,7 +37,28 @@ class Repository::Bazaar < Repository
     'Bazaar'
   end
 
+  def entry(path=nil, identifier=nil)
+    scm.bzr_path_encodig = log_encoding
+    scm.entry(path, identifier)
+  end
+
+  def cat(path, identifier=nil)
+    scm.bzr_path_encodig = log_encoding
+    scm.cat(path, identifier)
+  end
+
+  def annotate(path, identifier=nil)
+    scm.bzr_path_encodig = log_encoding
+    scm.annotate(path, identifier)
+  end
+
+  def diff(path, rev, rev_to)
+    scm.bzr_path_encodig = log_encoding
+    scm.diff(path, rev, rev_to)
+  end
+
   def entries(path=nil, identifier=nil)
+    scm.bzr_path_encodig = log_encoding
     entries = scm.entries(path, identifier)
     if entries
       entries.each do |e|
@@ -68,6 +89,7 @@ class Repository::Bazaar < Repository
   end
 
   def fetch_changesets
+    scm.bzr_path_encodig = log_encoding
     scm_info = scm.info
     if scm_info
       # latest revision found in database
index 7f04cda834338dde4a1d57a7dc00b050ed16d8d5..b2413f54950e10cea53d52b0c2412adc0aa42de4 100644 (file)
@@ -62,6 +62,10 @@ module Redmine
           super
         end
 
+        def bzr_path_encodig=(encoding)
+          @path_encoding = encoding
+        end
+
         # Get info about the repository
         def info
           cmd_args = %w|revno|