-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Feat: Add VCS change picker for current document and workspace #5472
Feat: Add VCS change picker for current document and workspace #5472
Conversation
I wanted something like this for a while but I held off implementing it because I think it's tricky to make this useful and create good UI for it. Right now you only show the first line on the left side of the picker. To make this useful you could show context (similar to how git diff shows context) in the preview line as that at-least makes more sense in terms of filtering. I am still not 100% sold on the single-file version of this. I am personally much more interested in the multi-file picker as that seems more more useful to me because you can filter by file. However the comments above (don't show the first file line, instead show context and a better preview) also apply here. |
@pascalkuthe here is the PR for tree explorer #2377 I'm referencing and it's the same used in the screenshot above |
Hmm I was about to work on something similar so I looked at your code. It looks like the To me, such a picker is most useful for picking up half-done work. So I could do IMHO the picker as currently designed isn't very useful - I can already navigate through the diffs very efficiently by doing And a changes picker is too noisy to be used as a changed files picker. |
Navigation by hunk in the current file is not useful to me. Like at all. I don't want to move, I just want to see what changed at quick glance, without the editor window moving at all. A picker solves that. Also, typing
I could show all the modified lines but I don't think that would be useful either, because if I write a 3 50-lines functions and add 7 imports, its going to have lots of noise for pretty much no real use We could do a thing where we split hunks bigger than N lines into different parts but I think that would be confusing if it was the default, though it could be very useful. Maybe for a future evolution, once we have user feedback ? Overall, I think having a base version with only the first line (or the line before for deletions) is good enough for a first version and to see what people will want. We could pin an issue asking for feedback ?
Agreed, all three pickers you mentionned in the issue seem nice, I'll do them all in separate commits
Yeah, it was simpler that way but I'll fix it, you're right it would be much better with all files instead of just the opened ones. |
I forgot you opened #5645 for the file change picker, I'll leave that one to you, let's not duplicate efforts, I'll just fix the workspace-hunks one :) |
I think I'll wait for #5645 to be merged, that way I'll be able to use the changes (notably changed files discovery) done there |
Alternatively, I could simply remove the workspace-changes picker for now and keep the current-buffer one, allowing both MR to progress in parallel, I'll do that instead :) |
606606f
to
184bc62
Compare
@poliorcetics Did you give up? |
Yes, I've been using |
Last year, when I worked on this, gitoxide wasn't advanced enough to correctly implement all I wanted, maybe that's changed now and it's possible ? I haven't checked where |
Closes #5362