Skip to content

Commit

Permalink
[PATCH] typo fixes to git-apply-patch-script
Browse files Browse the repository at this point in the history
When git-apply-patch-script creates a new file without
executable mode set, a typo caused it not to report that
activity to the user.  Also it was mistakenly running
git-update-cache twice for newly created or deleted paths.  This
patch fixes these problems.

Signed-off-by: Junio C Hamano <junkio@cox.net>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Junio C Hamano authored and Linus Torvalds committed May 2, 2005
1 parent dfcb405 commit 7fa76ee
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions git-apply-patch-script
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ test -f "$name.rej" || {
echo >&2 "created $name with mode +x."
chmod "$mode2" "$name"
;;
-)
-x)
echo >&2 "created $name."
;;
esac
Expand All @@ -52,9 +52,7 @@ test -f "$name.rej" || {
chmod "$mode2" "$name"
;;
esac
git-update-cache -- "$name"
esac
# This bit is debatable---the SCM may not want to keep
# cache in sync with the work tree (JIT does want to).
git-update-cache -- "$name"
}
exit 0

0 comments on commit 7fa76ee

Please sign in to comment.