mirror of
https://github.com/k88hudson/git-flight-rules.git
synced 2025-03-10 12:48:43 -03:00
Merge branch 'nzachow-master'
This commit is contained in:
commit
b67b184d8a
12
README.md
12
README.md
@ -94,6 +94,7 @@ All commands should work for at least git version 2.13.0. See the [git website](
|
||||
- [I want to find a string in any commit](#i-want-to-find-a-string-in-any-commit)
|
||||
- [I want to find by author/committer](#i-want-to-find-by-authorcommitter)
|
||||
- [I want to list commits containing specific files](#i-want-to-list-commits-containing-specific-files)
|
||||
- [I want to view the commit history for a specific function](#i-want-to-view-the-commit-history-for-a-specific-function)
|
||||
- [Find a tag where a commit is referenced](#find-a-tag-where-a-commit-is-referenced)
|
||||
- [Submodules](#submodules)
|
||||
- [Clone all submodules](#clone-all-submodules)
|
||||
@ -1355,6 +1356,17 @@ While using wildcards, it's useful to inform `--name-status` to see the list of
|
||||
$ git log --name-status -- **/*.js
|
||||
```
|
||||
|
||||
<a name="#i-want-to-view-the-commit-history-for-a-specific-function"></a>
|
||||
### I want to view the commit history for a specific function
|
||||
|
||||
To trace the evolution of a single function you can use:
|
||||
|
||||
```sh
|
||||
$ git log -L :FunctionName:FilePath
|
||||
```
|
||||
|
||||
Note that you can combine this with further `git log` options, like [revision ranges](https://git-scm.com/docs/gitrevisions) and [commit limits](https://git-scm.com/docs/git-log/#_commit_limiting).
|
||||
|
||||
### Find a tag where a commit is referenced
|
||||
|
||||
To find all tags containing a specific commit:
|
||||
|
Loading…
x
Reference in New Issue
Block a user