File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change 100
100
* [ Checkout a new branch without any history] ( https://github.com/git-tips/tips#checkout-a-new-branch-without-any-history )
101
101
* [ File diff between staging and the last file version.] ( https://github.com/git-tips/tips#file-diff-between-staging-and-the-last-file-version )
102
102
* [ Extract file from another branch.] ( https://github.com/git-tips/tips#extract-file-from-another-branch )
103
+ * [ List only the root and merge commits.] ( https://github.com/git-tips/tips#list-only-the-root-and-merge-commits )
103
104
104
105
<!-- Don’t remove or change the comment below – that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
105
106
<!-- @doxie.inject end toc -->
@@ -683,5 +684,10 @@ git diff --staged
683
684
git show < banch_name> :< file_name>
684
685
```
685
686
687
+ ## List only the root and merge commits.
688
+ ``` sh
689
+ git log --first-parent
690
+ ```
691
+
686
692
<!-- Don’t remove or change the comment below – that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
687
693
<!-- @doxie.inject end -->
Original file line number Diff line number Diff line change 305
305
},{
306
306
"title" : " Extract file from another branch." ,
307
307
"tip" : " git show <banch_name>:<file_name>"
308
+ }, {
309
+ "title" : " List only the root and merge commits." ,
310
+ "tip" : " git log --first-parent"
308
311
}]
You can’t perform that action at this time.
0 commit comments