Repository navigation
Revert "Add checkout --unstaged flag" - #1352
Merged
Merged
Conversation
Contributor
|
👍 Thanks for clarifying what |
Contributor
|
Works for me, thanks for the explanation 👍 |
Contributor
|
Tracking: #1334 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #1334
Reverts #1262
Reverting for possible re-submission later. The reasons are:
update-indexis unreliable at creating a clean git state, because the index cache may be out of date if the timestamp of files changes during checkout. Depending on the exact timing, the version of git, and the file system, precision issues can result in a non-clean status withoutupdate-index.--unstagedis misleading and the documentation "Do not add files to the index, keeping them unstaged." is incorrect.checkoutnever added anything to the index, it only made sure the index cache was not out of date.If the intention is to save the expense of calling
update-indexthen perhaps this feature can come back later in the form of a--no-update-indexflag or something, with a more accurate description of what it does; including mentioning that although it's faster, it might prevent the state returning to clean correctly in some cases.