开发者

Check first show up of code block in GIT

I would like to add @since params to开发者_运维技巧 my docblocks of class methods, how I can easily find first commit that have introduced that given method in class (not last modified like with git blame ) ?


Try git log -S'line of code here'

You can enter multiple lines of code between the quotes if you wish, and customise log output in all the usual ways (--oneline, -p etc.), and the command will also work with git diff and git format-patch.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜