aboutsummaryrefslogtreecommitdiff
path: root/doc/todo/git-rev-list_requires_relative_path___40__fixes_git_ctime__41__.mdwn
diff options
context:
space:
mode:
Diffstat (limited to 'doc/todo/git-rev-list_requires_relative_path___40__fixes_git_ctime__41__.mdwn')
-rw-r--r--doc/todo/git-rev-list_requires_relative_path___40__fixes_git_ctime__41__.mdwn24
1 files changed, 24 insertions, 0 deletions
diff --git a/doc/todo/git-rev-list_requires_relative_path___40__fixes_git_ctime__41__.mdwn b/doc/todo/git-rev-list_requires_relative_path___40__fixes_git_ctime__41__.mdwn
new file mode 100644
index 000000000..ec7d61b90
--- /dev/null
+++ b/doc/todo/git-rev-list_requires_relative_path___40__fixes_git_ctime__41__.mdwn
@@ -0,0 +1,24 @@
+ Index: IkiWiki/Rcs/git.pm
+ ===================================================================
+ --- IkiWiki/Rcs/git.pm (revision 4532)
+ +++ IkiWiki/Rcs/git.pm (working copy)
+ @@ -275,6 +275,9 @@
+
+ my $file = shift || q{--};
+
+ + # Remove srcdir prefix to appease git-rev-list
+ + $file =~ s/^$config{srcdir}\/?//;
+ +
+ # Ignore error since a non-existing file might be given.
+ my ($sha1) = run_or_non('git-rev-list', '--max-count=1', 'HEAD', $file);
+ if ($sha1) {
+
+I actually see a bug in this patch. :-) If srcdir = "foo" and the wiki
+contains a "foo/bar" and a "bar", this will make it, in the non-ctime case,
+get the sha1 of the wrong file, "bar", when "foo/bar" is asked for.
+
+Better to strip the path out in getctime, I guess.
+
+--[[Joey]]
+
+[[!tag patch done]]