]> git.pld-linux.org Git - packages/cvsspam.git/commitdiff
- add trac as web frontend support
authorElan Ruusamäe <glen@pld-linux.org>
Wed, 4 Mar 2009 19:51:42 +0000 (19:51 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    cvsspam-trac.patch -> 1.1

cvsspam-trac.patch [new file with mode: 0644]

diff --git a/cvsspam-trac.patch b/cvsspam-trac.patch
new file mode 100644 (file)
index 0000000..55f2351
--- /dev/null
@@ -0,0 +1,52 @@
+--- cvsspam-0.2.12/svn_cvsspam.rb~     2009-03-04 21:48:14.127883013 +0200
++++ cvsspam-0.2.12/svn_cvsspam.rb      2009-03-04 21:40:29.874933266 +0200
+@@ -831,6 +831,31 @@
+   end
+ end
++# Link to Trac
++class TracFrontend < WebFrontend
++  def path_url(path, tag)
++    add_repo("#{@base_url}browser/#{urlEncode(path)}")
++  end
++
++  def version_url(path, version)
++    add_repo("#{@base_url}browser/#{urlEncode(path)}?rev=#{version}")
++  end
++
++  def diff_url(file)
++    add_repo("#{@base_url}changeset/#{file.toVer}")
++  end
++
++  protected
++
++  def log_url(file)
++    if file.toVer
++      log_anchor = "?rev=#{file.toVer}"
++    else
++      log_anchor = ""
++    end
++    add_repo("#{@base_url}log/#{urlEncode(file.path)}#{log_anchor}")
++  end
++end
+ # in need of refactoring...
+@@ -1333,6 +1358,7 @@
+ $viewcvsURL = nil
+ $choraURL = nil
+ $cvswebURL = nil
++$tracURL = nil
+ $from_address = nil
+ $subjectPrefix = nil
+ $files_in_subject = false;
+@@ -1419,6 +1445,9 @@
+ elsif $cvswebURL !=nil
+   $cvswebURL << "/" unless $cvswebURL =~ /\/$/
+   $frontend = CVSwebFrontend.new($cvswebURL)
++elsif $tracURL !=nil
++  $tracURL << "/" unless $tracURL =~ /\/$/
++  $frontend = TracFrontend.new($tracURL)
+ else
+   $frontend = NoFrontend.new
+ end
This page took 0.088113 seconds and 4 git commands to generate.