Re: [PATCH 1/2] stash create: remove duplicate changes detection
Phillip Wood <phillip.wood123@gmail.com> writes:
Show 6 quoted lines
> From: Phillip Wood <phillip.wood@dunelm.org.uk>
>
> Before it creates a stash, git checks if there are any unstaged,
> or uncommitted changes. If there isn't anything to stash it bails
> out. Since ef0f0b4509 (stash: optimize `get_untracked_files()`
> and `check_changes()`, 2019-02-25) "git stash store" has checked
"store"? Aren't we talking about "create"?
> unreliable (the scripted version of "git stash store", called "git
> update-index -q --refresh" before looking for any changes).
Show 6 quoted lines
> Avoid checking for changes twice by removing the call to
> check_changes_tracked_files() from store_stash() and restore the return
> code handling in store_stash() that was removed by ef0f0b4509 so that
> we continue to exit 0 when there are no changes to stash. In principle
> we could remove the call to check_changes() from do_store_stash()
> instead, but then we'd need to pass in the list of untracked files.
Again "(do_)?store" -> "\1create"?