summaryrefslogtreecommitdiffstats
path: root/app/models/repository/cvs.rb
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2011-04-11 15:43:50 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2011-04-11 15:43:50 +0000
commit0a0819f81ee351ccec8072b0e83e67d12afc5bbc (patch)
tree697bd4892b4d3b122631ff78c6713b117a85a9d9 /app/models/repository/cvs.rb
parent28a8d62fe4d409369aa02cc8b84279113af4910c (diff)
downloadredmine-0a0819f81ee351ccec8072b0e83e67d12afc5bbc.tar.gz
redmine-0a0819f81ee351ccec8072b0e83e67d12afc5bbc.zip
scm: cvs: override annotate() in model.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5410 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models/repository/cvs.rb')
-rw-r--r--app/models/repository/cvs.rb13
1 files changed, 11 insertions, 2 deletions
diff --git a/app/models/repository/cvs.rb b/app/models/repository/cvs.rb
index c8f98852e..c11500c56 100644
--- a/app/models/repository/cvs.rb
+++ b/app/models/repository/cvs.rb
@@ -63,7 +63,7 @@ class Repository::Cvs < Repository
end
entries
end
-
+
def cat(path, identifier=nil)
rev = nil
if ! identifier.nil?
@@ -72,7 +72,16 @@ class Repository::Cvs < Repository
end
scm.cat(path, rev.nil? ? nil : rev.committed_on)
end
-
+
+ def annotate(path, identifier=nil)
+ rev = nil
+ if ! identifier.nil?
+ rev = changesets.find_by_revision(identifier)
+ return nil if rev.nil?
+ end
+ scm.annotate(path, rev.nil? ? nil : rev.committed_on)
+ end
+
def diff(path, rev, rev_to)
# convert rev to revision. CVS can't handle changesets here
diff=[]