Le samedi 6 septembre 2014 15:26:36 UTC+2, gituser a écrit :
> I am wondering if it's possible to determine if a specific line in the
> code (of the curent version of a file) was added or changed after a
> specific commit?
> Regards :)
Hey, yes it is. You can use git-log's *pickaxe interface *for this: the *-S*
and *-G *options make git-log search for commits whose diff match a string.
Specify a revision range and a path as usual to limit the "search zone".
*Eg:* This command looks for commits that add/change/delete lines matching
*"console.log"* in file *path/to/file* between revisions *deadbeef* and HEAD
$ git log -G'console.log' deadbeef.. -- path/to/file
Have a look at git-log's man page
<https://www.kernel.org/pub/software/scm/git/docs/git-log.html> for more
You received this message because you are subscribed to the Google Groups "Git
for human beings" group.
To unsubscribe from this group and stop receiving emails from it, send an email
For more options, visit https://groups.google.com/d/optout.