mhutchie / vscode-git-graph

View a Git Graph of your repository in Visual Studio Code, and easily perform Git actions from the graph.
https://marketplace.visualstudio.com/items?itemName=mhutchie.git-graph
Other
1.97k stars 253 forks source link

Checkout with submodule update #352

Closed kbernard-perso closed 3 years ago

kbernard-perso commented 4 years ago

First of all, thanks a lot for this extension, it is very handy.

I'm using git submodule and if I am not mistaken, there is no possibility to "checkout with submodule update..." in git graph. Do you think this feature would be usefull for others ?

Currently I have to do it through the terminal, it could be nice to have it in the dropdown menu when right-click on a branch/commit in the graph.

Best regards,

mhutchie commented 4 years ago

Hi @kbernard-perso, Thanks for raising this feature request!

My impression of Git Graph users, based on all the interactions I have with them across many channels, is that relatively few use submodules at all. This is inline with the current submodule support in Git Graph, where submodules can be interacted with like any other repo in Git Graph, and they can be switched to via the Commit Details View in the parent repository, but there are no parent -> submodule Git commands.

Although this feature would be easy to add, and no doubt useful to those users who use submodules, I think as soon as I released it I’d get requests for many other parent -> submodule Git commands. This shifts this small and easy request into part of a much larger group of features, that collectively require a significant amount of time to implement, and only benefit the same (relatively small) group of users.

If I were to implement this broader group of features, I’d have to decide on an approach that doesn’t add too many additional options onto the context menus (some are already getting quite full). I think I’d favour adding additional options onto the existing dialogs if it would be reasonable to do so.

I’ll keep this feature request open to gauge the interest from the Git Graph user community. I’d happily implement this, and the broader range of parent -> submodule Git commands, if enough interest was expressed.

kbernard-perso commented 4 years ago

Hi @mhutchie ,

I totally understand your point. I do not have the feeling you have about the number of users who are working with submodules and would be interested in the feature.

A solution to this would be to have a configurable context menu, or at least the possibility to add custom git command or git commands script by editing the settings.json.

This is only an idea, this might not be reasonable to modify your extension like this. As you said, this might only interest a small percentage of the people using your extension.

Best regards,

kbernard-perso commented 4 years ago

But like this you might fulfill, all at once, the needs of people like me who have "special" feature request.

mhutchie commented 3 years ago

This issue has been left open for over three months for others to express interest in this feature. As only four other Git Graph users have indicated they would like this functionality in this period, it seems to confirm my previous sentiment that this feature wouldn't be used by many users.

Although this functionality would definitely be nice to have, and would be useful to the users who use submodules, I still have the same reservations as I mentioned in my previous reply. Because of this, and the very small percentage of users who have indicated they would like this feature, I'll close it for now and move it to the backlog.

Note to users reading this in the future: If you'd like this functionality, please reply to this thread to express your interest. I'd happily re-evaluate, re-open and implement this feature if there was enough of an indication it would be used by a decent number of users.

igor-sirotin commented 3 years ago

Hi @mhutchie,

First of all, I would like to thank you for an amazing extension. I'm happy with it, it saves a lot of time for me and my colleagues.

I almost totally switch to it from TortoiseGit, the only thing that's missing for me is submodule support. I understand your point from previous reply, but I think there is one simple feature that would simplify submodule users' life and have no effect on anything. The idea comes from TortoiseGit, but it's kinda natural.

In graphs of repositories, which are submodules, it would be nice to have a "superproject-pointer" marker (or any kind of other design solution) for the commit, which is pointed by the parent repository. This way I can always see where the submodule should be checkout.

Here's a screenshot of this feature from TortoiseGit client: image

dlazenby commented 2 years ago

First, let me say thanks for making this tool, it is really quite good overall. But I am frustrated by the responses above for submodule management.

This issue has been left open for over three months for others to express interest in this feature. As only four other Git Graph users have indicated they would like this functionality in this period, it seems to confirm my previous sentiment that this feature wouldn't be used by many users.

I don't think this is a valid argument. Having used many tools, I would argue that most users probably fall into the camp of "the tool either does what I need it to do or I will find a tool that will" and most probably don't or won't take time to "vote" on a feature, especially in a place that they didn't realize they should be "voting" on the feature being added.

That being said, to close an issue because an "insufficient number" of users logged in and "thumbs upped" the open issue on GitHub within a 3 month window is not a valid calculation for how many users would find the feature useful. And I would not expect a "representative sample" of the overall user base to thumbs-up or respond to this issue ... ever.
I wouldn't have even found this page if I wasn't facing a great deal of pain that the proposed feature would alleviate, and in searching on how to enable the feature landed here via a Google search. Additionally, the fact that I am commenting on this thread at all is indication that I am highly vested in needing this functionality and feel that my best option at the moment is to plead with you on here to add it.

If I had an option to use Windows as my OS, I would have switched back to GitExtensions, but I am stuck with Linux at the moment of which this is the best tool that I have found.

I appreciate the effort you have put into this tool and the design considerations that you have undergone. I don't care if this feature (to manage submodules) makes it into a "context menu" or not. I would be entirely okay with it ending up in the overall tool settings as a tool-wide preference

To put my pain in perspective, I have about 3-4 active "parent" git repos, each with anywhere from 4 to 15+ submodules that they depend on (not my choice, but what I have to work with). So to manually go and find which branches EACH submodule needs to be on given the current parent branch is a major time suck. I guess I could just learn to manage everything through terminal commands, but I prefer the graphical client over the console since I am used to working with a Git GUI from my Windows days. So any help that you could provide in keeping parent repos and submodules in sync (especially during checkout) would be MUCH appreciated.

alexisfrjp commented 2 years ago

I started using submodules and, I believe adding a box to update/clone the submodules shouldn't impact anybody. If you don't want to fully support submodules that's fine, but I find annoying having to type a command every time I checkout a branch, just to get the submodules.

The choice will be let to the user to enable this box by default.

crackwitz commented 3 weeks ago

We use submodules extensively at work. This would make my life a lot easier.

Maybe I should badger my coworkers to raise their voice as well?