remove todo item
authorJoey Hess <joey@kitenet.net>
Fri, 8 Oct 2010 22:46:30 +0000 (18:46 -0400)
committerJoey Hess <joey@kitenet.net>
Fri, 8 Oct 2010 22:46:30 +0000 (18:46 -0400)
I understand the need to avoid chdir when running git_parse_changes
for receive now. At that point, the changes have not been pushed to
the srcdir's repo yet. When running the same code for preprevert,
chdir to the srcdir is ok, and necessary.

IkiWiki/Plugin/git.pm
doc/todo/web_reversion.mdwn

index 48e71aa9aedfcf897996fa7d032d054af52717dc..47e806209804e97f28c3be5ebaba30a300bc577a 100644 (file)
@@ -794,8 +794,6 @@ sub git_parse_changes {
                                die $@ if $@;
                                my $fh;
                                ($fh, $path)=File::Temp::tempfile("XXXXXXXXXX", UNLINK => 1);
-                               # Ensure we run this in the right place,
-                               # see comments in rcs_receive.
                                my $cmd = ($no_chdir ? '' : "cd $config{srcdir} && ")
                                        . "git show $detail->{sha1_to} > '$path'";
                                if (system($cmd) != 0) {
index 4335b3fbf65ad4290148a4472037d3e5de7bbdaa..212fd3a5333ca6d899987b0b7cad35e19b1296d5 100644 (file)
@@ -69,12 +69,5 @@ Peter Gammie has done an initial implementation of the above.
 
 >>> I have made my own revert branch and put a few fixes in there
 >>> [[!template id=gitbranch branch=origin/revert author="[[joey]]"]]
->>> (and fixed all the indention..). Issues I noticed but have not gotten
->>> to: --[[Joey]] 
+>>> (and fixed all the indention..). --[[Joey]] 
 >>>> Please change the git pointer above, then. I will work on your branch. -- [[peteg]]
-
->>> * I quite don't understand why one caller of `git_parse_changes`
->>>   needs it to chdir, and not the other one. It's running
->>>   in the same git repo either way, and git doesn't need
->>>   `git show` to run in a subdir at all..
->>>> I was aping (preserving) what was already there. I don't understand what you say about `git show` - it must run under $srcdir, surely? And empirically the CGI process wasn't in the right place. By all means simplify that. -- [[peteg]]