我使用的是Git和gitk的命令行版本。我希望看到完整的版本树,而不仅仅是从当前签出的版本中可以访问的部分。有可能吗?
发布于 2011-03-19 16:34:12
您可以尝试以下操作:
gitk --all
您可以使用git rev-list
understands的任何内容来告诉gitk
要显示什么,所以如果您只想要几个分支,可以这样做:
gitk master origin/master origin/experiment
..。或者更具异国情调的东西,比如:
gitk --simplify-by-decoration --all
发布于 2011-03-19 18:30:40
如果您碰巧没有可用的图形界面,您还可以在命令行上打印出提交图:
git log --oneline --graph --decorate --all
如果此命令报告--oneline选项无效,请使用:
git log --pretty=oneline --graph --decorate --all
发布于 2015-01-29 00:41:56
同样的问题也有一个very good answer。
在“~/.gitconfig”中添加以下行:
[alias]
lg1 = log --graph --abbrev-commit --decorate --date=relative --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --all
lg2 = log --graph --abbrev-commit --decorate --format=format:'%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an%C(reset)' --all
lg = !"git lg1"
https://stackoverflow.com/questions/5361019
复制相似问题