Thread (92 messages) 92 messages, 9 authors, 2021-12-01

Re: [PATCH v2 1/7] reset: behave correctly with sparse-checkout

From: Bagas Sanjaya <hidden>
Date: 2021-10-06 10:31:25

On 05/10/21 20.20, Kevin Willford via GitGitGadget wrote:
When using the sparse checkout feature, 'git reset' will add entries to
the index that will have the skip-worktree bit off but will leave the
working directory empty. File data is lost because the index version of
the files has been changed but there is nothing that is in the working
directory. This will cause the next 'git status' call to show either
deleted for files modified or deleting or nothing for files added. The
added files should be shown as untracked and modified files should be
shown as modified.
Better say `... but there is nothing in the working directory`.
To fix this when the reset is running if there is not a file in the
working directory and if it will be missing with the new index entry or
was not missing in the previous version, we create the previous index
version of the file in the working directory so that status will report
correctly and the files will be availble for the user to deal with.
s/availble/available

-- 
An old man doll... just what I always wanted! - Clara
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help