summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 7c390d9)
raw | patch | inline | side by side (parent: 7c390d9)
author | Junio C Hamano <gitster@pobox.com> | |
Sat, 5 Jan 2008 09:35:54 +0000 (01:35 -0800) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 7 Jan 2008 02:41:36 +0000 (18:41 -0800) |
Because it is so tempting to expect "git stash clear stash@{4}"
to remove the fourth element in the stash while leaving other
elements intact, we should not blindly throw away everything
upon seeing such a command.
This may change when we start using "git reflog delete" to
selectively nuke a single (or multiple, for that matter) stash
entries with such a command line.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
to remove the fourth element in the stash while leaving other
elements intact, we should not blindly throw away everything
upon seeing such a command.
This may change when we start using "git reflog delete" to
selectively nuke a single (or multiple, for that matter) stash
entries with such a command line.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-stash.sh | patch | blob | history |
diff --git a/git-stash.sh b/git-stash.sh
index 4d5e5c0be7941b48fcf33364ee36d08d626ea487..b00f8881693ff09516ea058816dc96697ca56483 100755 (executable)
--- a/git-stash.sh
+++ b/git-stash.sh
}
clear_stash () {
+ if test $# != 0
+ then
+ die "git stash clear with parameters is unimplemented"
+ fi
if current=$(git rev-parse --verify $ref_stash 2>/dev/null)
then
git update-ref -d $ref_stash $current
apply_stash "$@"
;;
clear)
- clear_stash
+ shift
+ clear_stash "$@"
;;
create)
if test $# -gt 0 && test "$1" = create