]> git.lizzy.rs Git - plan9front.git/commitdiff
git/revert: fix previous commit (helps if you save the file, thanks qwx)
authorOri Bernstein <ori@eigenstate.org>
Mon, 28 Jun 2021 23:40:40 +0000 (23:40 +0000)
committerOri Bernstein <ori@eigenstate.org>
Mon, 28 Jun 2021 23:40:40 +0000 (23:40 +0000)
git/revert: fix previous commit (helps if you save the file, thanks qwx)

sys/src/cmd/git/revert

index 0f11d82a9144aa49990f105e660db2155e44e2d2..4a7cff71bd7530966648d66ce39f69900c83f914 100644 (file)
@@ -15,8 +15,8 @@ files=`$nl{cleanname -d $gitrel $*}
 for(f in `$nl{cd $commit/tree/ && walk -f $files}){
        mkdir -p `{basename -d $f}
        if(cp -x -- $commit/tree/$f $f)
-               walk -eq $m > .git/index9/tracked/$m
+               walk -eq $f > .git/index9/tracked/$f
        if not
-               echo -n > .git/index9/tracked/$m
+               echo -n > .git/index9/tracked/$f
 }
 exit ''