Open cleidigh opened 6 years ago
@joaomoreno Would you accept a PR on this? Or do you want to keep it internal?
I'm not sure how this could look like. What are your thoughts?
@joaomoreno
As stated before , the use case is mainly cleaning up local commits in preparation for single commit PRs as is preferred for projects like VSC
@joaomoreno I guess the other option is doing this through an extension (GitLens) if you think that would be better. Either way it would be great to have your opinion on the approach above.
I think getting started with an extension would be a great way to prototype this thing. Gitlens would not be ideal since it seems that extension, though powerful, dedicates itself to a read-only view of repositories.
Since git is now an extension, it could actually expose API to other extensions to give them the full power of git: #31103. This could open the door to explore new features as extensions, such as the one we mention here.
Finally, one thing seems to be missing from this story: squashing is but a small part of a much powerful feature, rebasing, which we should probably tackle first.
@joaomoreno Great. Thanks for discussion points ! I get that rebasing is the main feature. Let me to do more research as I am no git guru then I will put out a proposal for an extension approaching rebasing first.
Should I change the title of this issue to reflect a discussion on rebasing?
Any update on this? Would be really good to have squash supported directly by VSCode with the UI supporting it
I have started working on some initial rebase features. Here is what I have so far:
When a rebase is in progress, the rebase command shows the "Continue", "Abort", and "Skip" options.
This command lets you choose a branch to rebase onto the current branch. If there are any conflicts, you can resolve them manually and run the "Rebase: Continue" command. Repeat this process until all conflicts are resolved (like you normally would with git rebase
) and it tells you that the rebase is complete.
This command lets you choose a commit to consolidate back to, and then opens up the git interactive rebase file for editing. The ability to squash all commits and add a new commit message without having to edit the text file could be a specific option added in the future.
Feedback would be appreciated on what other features to add and how it looks so far. Thanks!
@jmbockhorst That is exactly what i want! Looks amazing. Will it be released to insiders?
Any feedback on the above rebasing features? Should I create a PR as it is currently?
This is exactly what I miss after switching from SmartGit to VS Code for git. So, please create a PR :)
Some possible features, borrowed from https://github.com/git-up/GitUp:
@jmbockhorst would you be willing to open a PR with the impressive features you demoed? If more features are desired, they could go in a separate PR, or someone else could build atop of your hard work.
This fixed it for me:
git config --global core.editor "code --new-window --wait"
The difference from prior solutions is the --new-window
option which forces to open a new window.
Past Issues:
Now that VSCode for the web and github.dev
exist, it would be really nice to be able to do an interactive rebase using the VSCode UI, since these environments lack a terminal.
any updates? lack of interactive rebase in github.dev is a huge pain!
I'd say Continue and Abort operations are needed for the normal Merge and Cherry-Pick workflows, too. #193042
Since it is typical for projects like Code and others to have PRs with a single command for brevity and cleanliness, this feature would be really helpful to not have to go into the terminal.
Willing to do a PR...