David Summers <david@summersoft.fay.ar.us> writes:
> Is there an example svn-log.cgi somewhere that I've missed? If not then
> I'll hack one together and post it for inspection and introduction into
> the tools/ directory.
Here are the two scripts we have on svn.collab.net:
/usr/www/docroot/svn-log.cgi looks like this:
#!/bin/sh
echo "Content-type: text/plain"
echo ""
/usr/www/repositories/svn_logs.pl ../repositories/svn
And /usr/www/repositories/svn-log.pl is this:
#!/usr/bin/perl
use strict;
my $repos = shift @ARGV;
# Make sure we got all the arguments we wanted
if ((not defined $repos) or ($repos eq ''))
{
print "Usage: svn_logs.pl REPOS-PATH\n\n";
exit;
}
# Get the youngest revision in the repository.
my $youngest = `svnadmin youngest $repos`;
chomp $youngest; # don't want carriage return
die ("Error using svnadmin to get youngest revision") if (not $youngest =~ /^\d/);
while ($youngest >= 1)
{
print "--------------------------------------------------------\n";
print "Revision $youngest\n";
print `svnlook $repos rev $youngest info`;
print "\n";
$youngest--;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Oct 21 14:37:00 2006