This commit is contained in:
Hemanth.HM 2016-04-29 20:18:50 +05:30
parent 168303734b
commit b238e44ff1
2 changed files with 9 additions and 0 deletions

View File

@ -99,6 +99,7 @@
* [Remove entry in the global config.](https://github.com/git-tips/tips#remove-entry-in-the-global-config)
* [Checkout a new branch without any history](https://github.com/git-tips/tips#checkout-a-new-branch-without-any-history)
* [File diff between staging and the last file version.](https://github.com/git-tips/tips#file-diff-between-staging-and-the-last-file-version)
* [Extract file from another branch.](https://github.com/git-tips/tips#extract-file-from-another-branch)
<!-- Dont remove or change the comment below that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
<!-- @doxie.inject end toc -->
@ -677,5 +678,10 @@ git checkout --orphan <branch_name>
git diff --staged
```
## Extract file from another branch.
```sh
git show <banch_name>:<file_name>
```
<!-- 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

@ -302,4 +302,7 @@
},{
"title": "File diff between staging and the last file version.",
"tip": "git diff --staged"
},{
"title": "Extract file from another branch.",
"tip": "git show <banch_name>:<file_name>"
}]