2016-02-11 51 views

回答

3

你的命令几乎是正确的:

git show tag-name:foo.bin > foo-tag-name.bin 

git help show还给出了另一个例子:

git show next~10:Documentation/README 
     Shows the contents of the file Documentation/README as they were 
     current in the 10th last commit of the branch next. 

这句法中git help gitrevisions描述:

<rev>:<path>, e.g. HEAD:README, :README, master:./README 
     A suffix : followed by a path names the blob or tree at the given 
     path in the tree-ish object named by the part before the colon. 
+0

谢谢,我不知道,'混帐show'可以处理二进制的文件。 – sergej

1

git show是你要找的命令:

git show tag-name:foo.bin > foo-tag-name.bin 
相关问题