mirror of
https://github.com/namibia/tips.git
synced 2024-11-14 09:14:06 +00:00
Add tip: git log -n
This commit is contained in:
parent
2e8cfda782
commit
6fd5b4b52d
12
README.md
12
README.md
@ -104,6 +104,7 @@ P.S: All these commands are tested on `git version 2.7.4 (Apple Git-66)`.
|
|||||||
* [List ignored files.](#list-ignored-files)
|
* [List ignored files.](#list-ignored-files)
|
||||||
* [Status of ignored files.](#status-of-ignored-files)
|
* [Status of ignored files.](#status-of-ignored-files)
|
||||||
* [Commits in Branch1 that are not in Branch2](#commits-in-branch1-that-are-not-in-branch2)
|
* [Commits in Branch1 that are not in Branch2](#commits-in-branch1-that-are-not-in-branch2)
|
||||||
|
* [List n last commits](#list-n-last-commits)
|
||||||
* [Reuse recorded resolution, record and reuse previous conflicts resolutions.](#reuse-recorded-resolution-record-and-reuse-previous-conflicts-resolutions)
|
* [Reuse recorded resolution, record and reuse previous conflicts resolutions.](#reuse-recorded-resolution-record-and-reuse-previous-conflicts-resolutions)
|
||||||
* [Open all conflicted files in an editor.](#open-all-conflicted-files-in-an-editor)
|
* [Open all conflicted files in an editor.](#open-all-conflicted-files-in-an-editor)
|
||||||
* [Count unpacked number of objects and their disk consumption.](#count-unpacked-number-of-objects-and-their-disk-consumption)
|
* [Count unpacked number of objects and their disk consumption.](#count-unpacked-number-of-objects-and-their-disk-consumption)
|
||||||
@ -777,6 +778,17 @@ git status --ignored
|
|||||||
git log Branch1 ^Branch2
|
git log Branch1 ^Branch2
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## List n last commits
|
||||||
|
```sh
|
||||||
|
git log -<n>
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
__Alternatives:__
|
||||||
|
```sh
|
||||||
|
git log -n <n>
|
||||||
|
```
|
||||||
|
|
||||||
## Reuse recorded resolution, record and reuse previous conflicts resolutions.
|
## Reuse recorded resolution, record and reuse previous conflicts resolutions.
|
||||||
```sh
|
```sh
|
||||||
git config --global rerere.enabled 1
|
git config --global rerere.enabled 1
|
||||||
|
@ -300,6 +300,10 @@
|
|||||||
}, {
|
}, {
|
||||||
"title": "Commits in Branch1 that are not in Branch2",
|
"title": "Commits in Branch1 that are not in Branch2",
|
||||||
"tip": "git log Branch1 ^Branch2"
|
"tip": "git log Branch1 ^Branch2"
|
||||||
|
}, {
|
||||||
|
"title": "List n last commits",
|
||||||
|
"tip": "git log -<n>",
|
||||||
|
"alternatives": ["git log -n <n>"]
|
||||||
}, {
|
}, {
|
||||||
"title": "Reuse recorded resolution, record and reuse previous conflicts resolutions.",
|
"title": "Reuse recorded resolution, record and reuse previous conflicts resolutions.",
|
||||||
"tip": "git config --global rerere.enabled 1"
|
"tip": "git config --global rerere.enabled 1"
|
||||||
|
Loading…
Reference in New Issue
Block a user