diff options
Diffstat (limited to 'IkiWiki/Plugin')
-rw-r--r-- | IkiWiki/Plugin/cvs.pm | 2 | ||||
-rw-r--r-- | IkiWiki/Plugin/darcs.pm | 9 | ||||
-rw-r--r-- | IkiWiki/Plugin/git.pm | 3 | ||||
-rw-r--r-- | IkiWiki/Plugin/mercurial.pm | 2 | ||||
-rw-r--r-- | IkiWiki/Plugin/svn.pm | 6 |
5 files changed, 8 insertions, 14 deletions
diff --git a/IkiWiki/Plugin/cvs.pm b/IkiWiki/Plugin/cvs.pm index c6687d780..1a432c052 100644 --- a/IkiWiki/Plugin/cvs.pm +++ b/IkiWiki/Plugin/cvs.pm @@ -459,7 +459,7 @@ sub rcs_diff ($) { } sub rcs_getctime ($) { - my $file=shift; + my $file=$config{srcdir}."/".shift(); my $cvs_log_infoline=qr/^date: (.+);\s+author/; diff --git a/IkiWiki/Plugin/darcs.pm b/IkiWiki/Plugin/darcs.pm index 0dfc8708d..0f63b8807 100644 --- a/IkiWiki/Plugin/darcs.pm +++ b/IkiWiki/Plugin/darcs.pm @@ -396,14 +396,11 @@ sub rcs_getctime ($) { eval q{use XML::Simple}; local $/=undef; - my $filer=substr($file, length($config{srcdir})); - $filer =~ s:^[/]+::; - my $child = open(LOG, "-|"); if (! $child) { exec("darcs", "changes", "--xml", "--reverse", - "--repodir", $config{srcdir}, $filer) - || error("'darcs changes $filer' failed to run"); + "--repodir", $config{srcdir}, $file) + || error("'darcs changes $file' failed to run"); } my $data; @@ -418,7 +415,7 @@ sub rcs_getctime ($) { my $datestr = $log->{patch}[0]->{local_date}; if (! defined $datestr) { - warn "failed to get ctime for $filer"; + warn "failed to get ctime for $file"; return 0; } diff --git a/IkiWiki/Plugin/git.pm b/IkiWiki/Plugin/git.pm index b02fc118d..85368606e 100644 --- a/IkiWiki/Plugin/git.pm +++ b/IkiWiki/Plugin/git.pm @@ -658,9 +658,6 @@ sub findtimes ($$) { my $file=shift; my $id=shift; # 0 = mtime ; 1 = ctime - # Remove srcdir prefix - $file =~ s/^\Q$config{srcdir}\E\/?//; - if (! keys %time_cache) { my $date; foreach my $line (run_or_die('git', 'log', diff --git a/IkiWiki/Plugin/mercurial.pm b/IkiWiki/Plugin/mercurial.pm index edf915ae9..59dc63b4e 100644 --- a/IkiWiki/Plugin/mercurial.pm +++ b/IkiWiki/Plugin/mercurial.pm @@ -237,7 +237,7 @@ sub rcs_getctime ($) { my ($file) = @_; my @cmdline = ("hg", "-R", $config{srcdir}, "log", "-v", - "--style", "default", $file); + "--style", "default", "$config{srcdir}/$file"); open (my $out, "-|", @cmdline); my @log = (mercurial_log($out)); diff --git a/IkiWiki/Plugin/svn.pm b/IkiWiki/Plugin/svn.pm index f1e608408..9cf82b5db 100644 --- a/IkiWiki/Plugin/svn.pm +++ b/IkiWiki/Plugin/svn.pm @@ -366,7 +366,7 @@ sub findtimes ($) { my $child = open(SVNLOG, "-|"); if (! $child) { - exec("svn", "log", $file) || error("svn log $file failed to run"); + exec("svn", "log", "$config{srcdir}/$file") || error("svn log failed to run"); } my ($cdate, $mdate); @@ -376,10 +376,10 @@ sub findtimes ($) { $mdate=$1 unless defined $mdate; } } - close SVNLOG || error "svn log $file exited $?"; + close SVNLOG || error "svn log exited $?"; if (! defined $cdate) { - error "failed to parse svn log for $file\n"; + error "failed to parse svn log for $file"; } eval q{use Date::Parse}; |