Skip to content
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

right click -> git checkout branch #972

Open
rdbende opened this issue Oct 22, 2021 · 8 comments
Open

right click -> git checkout branch #972

rdbende opened this issue Oct 22, 2021 · 8 comments

Comments

@rdbende
Copy link
Collaborator

rdbende commented Oct 22, 2021

Would be good to have a git checkout option when right clicking on repo root.

@Akuli
Copy link
Owner

Akuli commented Oct 22, 2021

git checkout can do (at least) two very different things. Do you mean git checkout branch or git checkout file?

@rdbende
Copy link
Collaborator Author

rdbende commented Oct 22, 2021

Yeah, I meant git checkout branch

@rdbende rdbende changed the title right click -> git checkout right click -> git checkout branch Oct 22, 2021
@Akuli
Copy link
Owner

Akuli commented Oct 22, 2021

If we add branch switching, we will also need to add something to show what branch you are on. Currently it is the only part of git status that is not shown anywhere in Porcupine. It would be even better to add something like git log --all --oneline --graph, which is a command I use all the time (with a shorter alias), and I don't ever do Git branches without it.

@rdbende
Copy link
Collaborator Author

rdbende commented Oct 22, 2021

Then it would be great to have a full Git frame with git lola and git branch stuff so that I don't have to press Super+1 all the time (that's my terminal). Although parsing git lola would be quite complicated.

@Akuli
Copy link
Owner

Akuli commented Oct 22, 2021

We will also have to think about whether we really want Porcupine to turn into a Git GUI, or do we want it to be just an editor. In my experience, if an editor includes a Git GUI, then:

  • Beginners use Git through the editor, and get confused when they need to do something on the command line (either because the editor's Git GUI doesn't have some functionality or doesn't show up in a google search about how to solve a specific problem with Git).
  • Experienced people (and beginners guided by experienced people) don't even bother with the editor's Git features, and they use Git through the terminal.

I'm sure there are exceptions, but that seems pretty rare. I can't think of any.

I think it's fine to add Git functionality to Porcupine, as long as it doesn't involve the concept of a commit. This way we can keep the useful coloring in the directory tree and even the git add buttons, but we won't end up making Porcupine into a full-featured Git client where beginners use 5% of the features and experienced people use none of them.

@rdbende
Copy link
Collaborator Author

rdbende commented Oct 22, 2021

Nor do I want Porcupine to become a Git GUI, but some git branch and git lola would be helpful, so you can see where you are, when editing. You'd still have to push, pull, commit and do other things in the terminal.

@Akuli
Copy link
Owner

Akuli commented Oct 22, 2021

If we add git lola support, it would be nice if you could right-click the commits to git show or git checkout them. For that we need git checkout support and also some kind of git show support. And why not also merging some branch by right-clicking it. But for merges we may end up with a conflict and Git asking for a commit message... and we just have implemented a full-featured Git client that nobody uses.

Which part of this chain of features is where we should stop, if we are going to add git lola?

@rdbende
Copy link
Collaborator Author

rdbende commented Jul 17, 2023

Actually, I would be happy with a simple label in the status bar that shows the current branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants