projects
/
git.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Finish git-am documentation.
[git.git]
/
git-reset.sh
diff --git
a/git-reset.sh
b/git-reset.sh
index
e028ff6
..
f9995ca
100755
(executable)
--- a/
git-reset.sh
+++ b/
git-reset.sh
@@
-60,7
+60,7
@@
then
else
rm -f "$GIT_DIR/ORIG_HEAD"
fi
else
rm -f "$GIT_DIR/ORIG_HEAD"
fi
-
echo "$rev" >"$GIT_DIR/HEAD
"
+
git-update-ref HEAD "$rev
"
case "$reset_type" in
--hard )
case "$reset_type" in
--hard )
@@
-81,10
+81,12
@@
case "$reset_type" in
while (<$fh>) {
chomp;
if (! exists $keep{$_}) {
while (<$fh>) {
chomp;
if (! exists $keep{$_}) {
- print "$_\0";
+ # it is ok if this fails -- it may already
+ # have been culled by checkout-index.
+ unlink $_;
}
}
}
}
- ' $tmp-exists
| xargs -0 rm -f --
+ ' $tmp-exists
;;
--soft )
;; # Nothing else to do
;;
--soft )
;; # Nothing else to do