Re: [PATCH] stash: Add --include-untracked option to stash and remove all untracked files
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jun 26, 2011, 20:02 UTC
- Message-ID
- <7vliwoz7ht.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <1308963366-1697-1-git-send-email-david@porkrind.org>
David Caldwell <david@porkrind.org> writes:
Show 5 quoted lines
> @@ -49,6 +57,7 @@ clear_stash () {
>
> create_stash () {
> stash_msg="$1"
> + untracked="$2"Hmm...
Show 6 quoted lines
> @@ -173,7 +213,7 @@ save_stash () {
> test -f "$GIT_DIR/logs/$ref_stash" ||
> clear_stash || die "Cannot initialize stash"
>
> - create_stash "$stash_msg"
> + create_stash "$stash_msg" $untrackedJust a minor nit from internal API point of view, I would prefer to see something like
create_stash --untracked=all "message"
or even
create_stash --untracked=all --message="message"
once you start enriching these functions with optional behaviour.