New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
stash: do not return before restoring untracked files #1180
Conversation
In commit bee8691 ("stash: restore untracked files AFTER restoring tracked files", 2021-09-10), we correctly identified that we should restore changes to tracked files before attempting to restore untracked files, and accordingly moved the code for restoring untracked files a few lines down in do_apply_stash(). Unfortunately, the intervening lines had some early return statements meaning that we suddenly stopped restoring untracked files in some cases. Even before the previous commit, there was another possible issue with the current code -- a post-stash-apply 'git status' that was intended to be run after restoring the stash was skipped when we hit a conflict (or other error condition), which seems slightly inconsistent. Fix both issues by saving the return status, and letting other functionality run before returning. Reported-by: AJ Henderson Test-case-by: Randall S. Becker <randall.becker@nexbridge.ca> Signed-off-by: Elijah Newren <newren@gmail.com>
/submit |
Submitted as pull.1180.git.git.1641337498996.gitgitgadget@gmail.com To fetch this version into
To fetch this version to local tag
|
On the Git mailing list, Junio C Hamano wrote (reply to this):
|
This branch is now known as |
This patch series was integrated into seen via 072f1f4. |
This patch series was integrated into seen via df1d068. |
This patch series was integrated into seen via 6f937bd. |
There was a status update in the "New Topics" section about the branch "git stash apply" forgot to attempt restoring untracked files when it failed to restore changes to tracked ones. Will merge to 'next'. source: <pull.1180.git.git.1641337498996.gitgitgadget@gmail.com> |
This patch series was integrated into seen via b1d5a92. |
This patch series was integrated into next via 22d0c6c. |
This patch series was integrated into seen via 6e22345. |
This patch series was integrated into next via 6e22345. |
This patch series was integrated into master via 6e22345. |
Closed via 6e22345. |
This fixes a regression in v2.34.1 relative to v2.33.0.