]> git.ipfire.org Git - thirdparty/git.git/commit
Merge branch 'hn/git-checkout-m-with-stash'
authorJunio C Hamano <gitster@pobox.com>
Sun, 17 May 2026 13:58:30 +0000 (22:58 +0900)
committerJunio C Hamano <gitster@pobox.com>
Sun, 17 May 2026 13:58:31 +0000 (22:58 +0900)
commitd17a7b8191d59e387e728ff60c2e226fa6c940bc
tree6eb5135c6c3fc032ba0b5d81b397bd17d3eb9cd2
parent068c10c7413fee5a69db1a46fb32f335675b25ca
parentc07039ebc4bbf2eb6c852fb1280891a448d1bf48
Merge branch 'hn/git-checkout-m-with-stash'

"git checkout -m another-branch" was invented to deal with local
changes to paths that are different between the current and the new
branch, but it gave only one chance to resolve conflicts.  The command
was taught to create a stash to save the local changes.

* hn/git-checkout-m-with-stash:
  checkout -m: autostash when switching branches
  checkout: rollback lock on early returns in merge_working_tree
  sequencer: teach autostash apply to take optional conflict marker labels
  sequencer: allow create_autostash to run silently
  stash: add --label-ours, --label-theirs, --label-base for apply
builtin/checkout.c