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

Add display handling of files added by git add -N #59163

Merged
merged 1 commit into from Dec 20, 2018

Conversation

Projects
None yet
2 participants
@ChristianAlexander
Copy link
Contributor

ChristianAlexander commented Sep 22, 2018

Relates to #42665

Adds support for displaying files which were added by git add -N.

According to man git-add:

-N, --intent-to-add
           Record only the fact that the path will be added later. An entry for the path is placed in the
           index with no content. This is useful for, among other things, showing the unstaged content of
           such files with git diff and committing them with git commit -a.

As files in this state are only present in the working tree (and not the index or a part of any merge behavior), this change adds them to the workingTree section of the git UI (usually localized as "Changes").

Because there is no previous version of the file available, only a right entry in the editor is created when opened, just like files which have a status of UNTRACKED.

Before:
before-intent-to-add

After:
intent-to-add

@ChristianAlexander ChristianAlexander changed the title Add display handling of files added by git add -N #42665 Add display handling of files added by git add -N Sep 22, 2018

@joaomoreno joaomoreno added the git label Sep 24, 2018

@joaomoreno joaomoreno added this to the Backlog milestone Sep 24, 2018

@joaomoreno joaomoreno merged commit 9d94600 into Microsoft:master Dec 20, 2018

2 checks passed

VS Code #20180922.8 succeeded with issues
Details
license/cla All CLA requirements met.
Details
@joaomoreno

This comment has been minimized.

Copy link
Member

joaomoreno commented Dec 20, 2018

Thanks! 🍻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment