From: Junio C Hamano <gitster@pobox.com>
To: Lidong Yan <yldhome2d2@gmail.com>
Cc: Eric Sunshine <sunshine@sunshineco.com>,
git@vger.kernel.org, j6t@kdbg.org
Subject: Re: [PATCH] pull: add pull.autoStash config option
Date: Wed, 16 Jul 2025 22:48:36 -0700 [thread overview]
Message-ID: <xmqq5xfr8j0r.fsf@gitster.g> (raw)
In-Reply-To: <174669ED-8E02-49BB-BD61-277DBCA4D890@gmail.com> (Lidong Yan's message of "Thu, 17 Jul 2025 13:01:42 +0800")
Lidong Yan <yldhome2d2@gmail.com> writes:
> Yeah. Though I considered that when pull.rebase = false, checking
> merge.autoStash instead of rebase.autoStashmight confuse users
> who rely on setting rebase.autoStash for their merge operations.
Yes, that would be a behaviour change, but it is just one time
thing. You notice your "git pull" do not autostash and instead
stops, you scratch your head and go read the documentation, and set
pull.autostash to true (which as I said I would not necessarily
recommend) or merge.autostash to true (which may not be as bad) and
move on.
I didn't consider it when I wrote my earlier message, but I like
your idea of defeating rebase.autostash and merge.autostash when
pull.autostash is explicitly set to false very much. With it, users
can set {rebase,merge}.autostash to true so that their local rebases
and merges, for which they are familiar with what both sides did,
would autostash (and autounstash), and set pull.autostash to false
so their "git pull" would be stopped when they have local changes
that would interfere with the operation, if they wanted to.
Thanks.
next prev parent reply other threads:[~2025-07-17 5:48 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-15 3:26 [BUG] git pull ignores pull.autostash=true configuration when used with --git-dir and --work-tree flags on a bare repository Bryan Lee
2025-07-15 4:09 ` Lidong Yan
2025-07-15 5:31 ` Bryan Lee
2025-07-15 15:02 ` Lidong Yan
2025-07-15 20:46 ` Junio C Hamano
2025-07-16 1:39 ` Lidong Yan
2025-07-16 5:55 ` Johannes Sixt
2025-07-16 11:20 ` Lidong Yan
2025-07-16 15:16 ` Junio C Hamano
2025-07-17 3:07 ` [PATCH] pull: add pull.autoStash config option Lidong Yan
2025-07-17 3:27 ` Eric Sunshine
2025-07-17 4:09 ` Lidong Yan
2025-07-17 4:37 ` Junio C Hamano
2025-07-17 5:01 ` Lidong Yan
2025-07-17 5:48 ` Junio C Hamano [this message]
2025-07-17 4:44 ` Junio C Hamano
2025-07-18 3:52 ` Lidong Yan
2025-07-18 22:13 ` Junio C Hamano
2025-07-19 3:14 ` Lidong Yan
2025-07-20 12:43 ` [PATCH v2] " Lidong Yan
2025-07-21 22:10 ` Junio C Hamano
2025-07-17 19:32 ` [BUG] git pull ignores pull.autostash=true configuration when used with --git-dir and --work-tree flags on a bare repository Ben Knoble
2025-07-15 5:31 ` Bryan Lee
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=xmqq5xfr8j0r.fsf@gitster.g \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=j6t@kdbg.org \
--cc=sunshine@sunshineco.com \
--cc=yldhome2d2@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).