yysun / git-tools

This extension provides a git changes tool window, a graphical git history viewer and menus to launch Git Bash, Git Extenstions and TortoiseGit.
http://yysun.github.com/git-tools
MIT License
78 stars 28 forks source link

Misleading info about file with both staged and unstaged modifications #14

Closed brunoleos closed 7 years ago

brunoleos commented 7 years ago

For a file with both staged and unstaged modifications, Git Changes shows one item for the file, with Modified status, which is misleading, because this status is shown for unstaged files, and Staged is shown for staged files. Besides, the modifications shown at the Diff View are both from staged and unstaged changes.

I would be very useful for me if I could have two different items at the left pane for this case:

Hope this is not so difficult to implement.

A feature I'm really after is the ability to select lines to stage, as git gui does, known as interactive staging (git add -i). Is it much difficult to implement something as the Visual Studio Merge, with checkboxes to select the modifications to stage?

yysun commented 7 years ago

When this project was started back in the time of VS 2008, one goal was to hide the concept of index/stage to make it easier for VS developers. Nowadays, more and more understand this concept and want to use it. Myself included.

I am thinking to make it into two modes: Simple mode: same as it as today, people can use it w/o bothering of staging Advance mode: make two grids, one for staged changes; one for unstaged changes; also support staging/unstaging by file chunks in the diff view

yysun commented 7 years ago

Pushed the adv-mode branch. It has the advanced mode that displays two lists: unstaged changes and staged changes. Plus the second feature you asked, which is implemented this way: you can select lines start with + or - in diff view, and then click a button to stage/unstage/reset the selected changes.

yysun commented 7 years ago

Preview: advanced-mode

brunoleos commented 7 years ago

That's it. Thanks for the great work, man.

I couldn't test this yet. Are you planning to update at the Marketplace? I'm not compiling from source.

yysun commented 7 years ago

2.0.0 is available in the marketplace.