[%# -*- Mode: perl; indent-tabs-mode: nil -*- # ***** BEGIN LICENSE BLOCK ***** # Version: MPL 1.1 # # The contents of this file are subject to the Mozilla Public License Version # 1.1 (the "License"); you may not use this file except in compliance with # the License. You may obtain a copy of the License at # http://www.mozilla.org/MPL/ # # Software distributed under the License is distributed on an "AS IS" basis, # WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License # for the specific language governing rights and limitations under the # License. # # The Original Code is the Application Registry. # # The Initial Developer of the Original Code is Mozilla Corporation. Portions # created by Mozilla Corporation are Copyright (C) 2007 Mozilla Foundation. # All Rights Reserved. # # Contributor(s): Dave Miller # # ***** END LICENSE BLOCK ***** -%] [%- USE CGI; filename = CGI.param('file'); dirname = CGI.param('dir'); cvsroot = CGI.param('cvsroot'); UNLESS cvsroot == '/cvsroot'; bonsai_root = bonsai_root _ '-' _ cvsroot.match('^/(.*)$').0; END; rev = CGI.param('rev'); prev_rev = CGI.param('prev_rev'); linked_text = CGI.param('linked_text'); SET linked_text = filename IF NOT linked_text; branch = CGI.param('branch'); SET branch = rev IF (NOT branch) OR rev.match('[A-Za-z]'); extralist = []; i = 0; WHILE CGI.param("u$i") OR CGI.param("t$i"); u = CGI.param("u$i"); t = CGI.param("t$i"); SET t = u IF NOT t; extralist.push( { url => u, text => t } ); i = i + 1; END; -%] [% linked_text FILTER html %] - Registry
[% IF extralist.size > 0 %] [% FOREACH extra IN extralist %] [% IF extra.url %] [% extra.text FILTER html %]
[% ELSE %] [% extra.text FILTER html %]
[% END %] [% END %]
[% END %] [% linked_text FILTER html %]
[% FILTER null; cgi = CGI.new(''); cgi.param('file', "$dirname/$filename"); cgi.param('rev', rev); cgi.param('cvsroot', cvsroot); END; -%] View Blame-Annotated Source
[% IF prev_rev %] [% FILTER null; cgi = CGI.new(''); cgi.param('diff_mode', 'context'); cgi.param('whitespace_mode', 'show'); cgi.param('root', cvsroot); cgi.param('subdir', dirname); cgi.param('command', 'DIFF_FRAMESET'); cgi.param('file', filename); cgi.param('rev1', rev); cgi.param('rev2', prev_rev); END; -%] View Diff [% prev_rev FILTER html %] vs. [% rev FILTER html %]
[% ELSE %] [% FILTER null; cgi = CGI.new(''); cgi.param('subdir', dirname); cgi.param('files', filename); cgi.param('command', 'DIRECTORY'); cgi.param('branch', branch); cgi.param('root', cvsroot); END; -%] View Diffs
[% END %] [% FILTER null; cgi = CGI.new(''); cgi.param('file', "$dirname/$filename"); cgi.param('rev', rev); cgi.param('root', cvsroot); END; - %] View Logs