简体   繁体   中英

How can I visualize GitHub branch history on Windows?

Every time I was thinking of switching all of our little team's projects to git / github, what pained me was that there didn't seem to be a tool to visualize all this social coding goodness.

When we all start wildly branching, forking and merging, I feel we're going to need a tool that would let us graphically see the full picture of our repository and its multitude of branches, in order to come up with a plan to merge it all back at some point into one and only truth (the proverbial origin/master ).

I've tried googling for such a visualization tool on several occasions, but came up empty handed. Was hoping that GitHub for Windows would solve this once and for all, but all it shows is linear history for a particular checked out branch.

What I'm looking for is something akin to what TortoiseHg has - a graph showing all branches and commits. Are you aware of any such tools? (We're on Windows.)

SourceTree seems friendlier than TortoiseGit for the graphs and you can interact with the graph as well.

源树

Stick with msysgit

gitk --all 

is what you want. From there you can even checkout branches, reset them, view diffs, etc.

For something quicker, I would suggest

git log --all --decorate --oneline --graph

This gets piped through less by default which gives you good navigation including search.

Another option is just to install linux in a VM (virual box is free) and use tig . You can ssh to the VM so you don't have to deal with the VM itself while using linux.

GitExtensions is your best bet.

在此处输入图片说明

TortoiseGit is ok, though in it's attempt to "protect us from ourselves", they hide some of the native power of Git. Fail.

SeeGit is an interesting project from Phil Haack that helps visualize things.

在此处输入图片说明

The best tool is the command-line and a quick command like this is probably easiest and most powerful:

git log --oneline --graph --decorate --all

That pretty much would have to be TortoiseGit since you are already familiar with TortoiseHg. (Check All Branches )

在此处输入图片说明

现在 VScode 有一个名为git-graph 的扩展,它最适合我的需要。

Depending on your push \\fetch \\ pull habits then you can either use the gitk viewer to see what you know locally (including the remotes you have fetched), or you can use the Network capability on Github to see what it has.

Just select a multi-forked project (with not too many forks;-) and click on the network tab to see how all the other forks relate to it.

Some times you do need to switch fork to get the view point you want, but it's not too much hassle, and for a small team it looks ok.

I have made recent suggestions to Github about selectivity for forks (to down select when there are a lot of forks to display).

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM