1
0
mirror of https://github.com/namibia/tips.git synced 2024-05-30 08:51:12 +00:00

Merge pull request #28 from p-v/cherry-patch

Tip to show all commits yet to be merged to master
This commit is contained in:
hemanth.hm 2015-08-17 13:18:30 +05:30
commit 9f996ee129
2 changed files with 18 additions and 1 deletions

View File

@ -48,6 +48,7 @@
* [Forcefully remove untracked files](https://github.com/git-tips/tips#forcefully-remove-untracked-files)
* [Forcefully remove untracked directory](https://github.com/git-tips/tips#forcefully-remove-untracked-directory)
* [Update all the submodules](https://github.com/git-tips/tips#update-all-the-submodules)
* [Show all commits in the current branch yet to be merged to master](https://github.com/git-tips/tips#show-all-commits-in-the-current-branch-yet-to-be-merged-to-master)
<!-- Dont remove or change the comment below that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
<!-- @doxie.inject end toc -->
@ -204,7 +205,7 @@ git log --no-merges --stat --reverse master..
## Pick commits across branches using cherry-pick
```sh
git checkout <branch-name> && git cherry-pick <commit-ish>
git checkout <branch-name> && cherry-pick <commit-ish>
```
## Find out branches containing commit-hash
@ -329,5 +330,16 @@ git clean -df
git submodule foreach git pull
```
## Show all commits in the current branch yet to be merged to master
```sh
git cherry -v master
```
__Alternatives:__
```sh
git cherry -v master <branch-to-be-merged>
```
<!-- Dont remove or change the comment below that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
<!-- @doxie.inject end -->

View File

@ -186,5 +186,10 @@
{
"title": "Update all the submodules",
"tip": "git submodule foreach git pull"
},
{
"title": "Show all commits in the current branch yet to be merged to master",
"tip": "git cherry -v master",
"alternatives": ["git cherry -v master <branch-to-be-merged>"]
}
]