-->

Call TortoiseGit's 'show log' by comma

2019-08-15 16:46发布

问题:

When entering a git-directory through the commandline in Windows I want a commandline which shows me the Tortoisegit's show log GUI.

So I want to avoid the open explorer->go to folder-click right->etc. thing, but I still want the nice looking show log graph of Tortoisegit.

How do I perform this in the cmd?

回答1:

When you are in command line interface (assume the PATH is good), just use:

TortoiseGitProc /command:log

otherwise,

TortoiseGitProc /command:log /path:"the\path\you\want\to\open\log"


cf. TortoiseGit Manual - Appendix D. Automating TortoiseGit


For getting the exact command argument, go to TortoiseGit -> Settings -> Advanced tree node -> set Option "Debug" value to true.

Then open the log via normal way, you will get extra message dialog. Something like:

Then use Ctrl + C to copy the whole message, and paste it to somewhere, ex: notepad, and reuse the command line.

(BTW, you can easily ignore the /hwnd argument.)