Hello Friends
About Git working in a Terminal
- Do you have recommendation of a tool where is possible see the git branches (history)?
Again, It in the terminal being TUI (Terminal User Interface) or not
Thanks in advance
Hello Friends
About Git working in a Terminal
Again, It in the terminal being TUI (Terminal User Interface) or not
Thanks in advance
I have not used it but saw something called “tig”.
On Ubuntu:
sudo apt install tig
Not sure if that’s what you are looking for or not.
I found something call Lazygit.
Tig is really great.
not sure about git branch’s history - but - I use ZSH shell an oh-my-ZSH - many of the oh-my-ZSH themes show a whole bunch of git information in the prompt if you’re in a folder that’s managed by git (i.e. probably looks for a .git folder)…
Some themes give a whole heap of info - others - like the one I use gnzh - show the barest - e.g. if I cd to a dir that’s part (or was once) a git repo you get ‹main*› added to your shell prompt :
There are other oh-my-zsh themes that show a lot more info about the git repo you’re navigating…
I can’t remember what ZSH looks like without oh-my-zsh…
I think fish shell also (or can) have similar features…
I don’t use fish shell (I think @Rosika uses it - some distros default to fish shell). But I use zsh and oh-my-zsh :
There’s a library of themes and “screenshots” - and some of them show a lot more info about the git information in your $PWD (current working directory)…
git log --oneline --graph
OK, nobody really needs tig. But there is more comfort with it, as it can show the diffs while browsing the log.
Every time you choose one of these addon extras, you introduce another layer of bugs and complexity.
What still would be nice to have is a terminal tool for rebasing.
What does rebasing mean?
Rewriting the history with git rebase -i or moving/attaching a branch elsewhere.
Huge thanks to all for the replies
Tim
I have not used it but saw something called “tig”.
Thanks for that suggestion. I arrived to the Tig: text-mode interface for Git page
Now, because at the Tig Screenshots page is available the The revision graph Figure which opens the The revision graph Figure (at flickr): I selected your post as solution
Howard
I found something call Lazygit.
Excellent suggestion too (sadly I can’t mark it as solution too). I arrived to the lazygit page
Dan
but - I use ZSH shell an oh-my-ZSH
The Oh My ZSH “shell” is in my TODO list yet. I watched some videos on YouTube and is very useful
Neville
git log --oneline --graph
I have the following alias ![]()
adog = log --all --decorate --oneline --graphSo I use the git adog command
The comparison is quicker
git log --oneline --graph
git log --all --decorate --oneline --graph
But is curious, the outputs are the same. I am assuming there is a special case to see their difference
Thanks to all!!!
Well, --all means all branches. If you have only one branch (master/main or whatever), the output will not differ. And in this case, --graph is superfluous.
Well,
--allmeans all branches. If you have only one branch (master/main or whatever), the output will not differ.
Oh correct, good point!