Support icon indicating copy to clipboard operation
Support copied to clipboard

[Feature request] Open terminal in repository folder

Open stuzer05 opened this issue 5 years ago • 8 comments

Would be great to have a menu button to open terminal in a root of the repository in case you have to manually do something.

stuzer05 avatar Mar 06 '20 19:03 stuzer05

This would be nice to have. One thing that's caused me to put this off is that I don't know the users prefered terminal, though maybe this isn't a big deal.

Something you can do right now is Repo -> Open Repo in File Browser. You could then open your terminal from there. I'm considering making easier. E.g. Right-click on the background.

GitFiend avatar Mar 06 '20 21:03 GitFiend

@GitFiend I think it will be convenient to run a default terminal on windows and I'm sure there are ways to do it in Linux as well (exo-open --launch TerminalEmulator on XFCE desktop env)` it's important to add a setting to allow user to change the terminal. For example, to let specify the path to terminal and a command to execute.

Let %s be a path to the repo directory, so user could set his terminal as gnome-terminal -- bash -c "cd %s"

This will allow any user on any system to setup the right terminal (if terminal supports initial commands, of course).

stuzer05 avatar Mar 06 '20 21:03 stuzer05

Yes, I agree with that train of logic. The problem is this now feels too complex and yuck to me. If I discover a more elegant way of implementing it I will consider it.

GitFiend avatar Mar 06 '20 22:03 GitFiend

@GitFiend Unfortunately, there is no way anyone can do a 100% working terminal detection system on every current and future OS. What I'm saying is that an auto-detection is a must yet manual setting cannot be left behind, as user should be able to change the default terminal (for example to ConEmu on windows). Or in case auto-detection didn't work correctly. There are many reasons manual terminal setting is a great solution alongside with auto-detection of the default terminal. Manual setting could be a fast yet 100% working solution for this menu button feature.

stuzer05 avatar Mar 07 '20 01:03 stuzer05

I see this way of working in nearly all git clients (which have this feature) and it's bothering many people (incl. me) some of them lack the feature of changing the default terminal application. On windows, for example, I prefer to use ConEmu instead of the default cmd.

stuzer05 avatar Mar 07 '20 01:03 stuzer05

Yeah, when I use Windows I use Cmder. I would want GitFiend to split my current window rather than making a new tab or new window. Because of this, I wouldn't use this feature. I agree with the logic in what you are saying. I just don't want to spend time implementing features that I can't be fully happy with and I don't love. I would rather implement the missing feature that sent you to the terminal in the first place.

I found your comment about you and others being bothered by not having the option to set a default interesting. I love hearing more about problems and frustrations than I do about solutions. That's the sort of feedback that makes me reconsider and change my mind.

GitFiend avatar Mar 07 '20 03:03 GitFiend

Well, you cannot cover all problems which could be solved with an open terminal. I often need to quickly change some file, make a merge without committing --no-commit (would be nice to have some kind of checkbox btw). I want to say is that terminal is so essential, it's hard to oversell it's importance.

stuzer05 avatar Mar 07 '20 03:03 stuzer05

That's fair enough. I usually already have a terminal open for the repo I'm working in. For me, this is about focus. I want GitFiend to be only as complicated as it needs to be. I feel it's the job of your operating system to launch apps, not GitFiend.

GitFiend avatar Mar 07 '20 04:03 GitFiend