mirror of
https://github.com/namibia/tips.git
synced 2025-02-03 03:58:24 +00:00
Merge pull request #101 from munendrasn/master
Add tip to unstage staged file
This commit is contained in:
commit
8d53a4974d
@ -122,6 +122,7 @@ P.S: All these commands are tested on `git version 2.7.4 (Apple Git-66)`.
|
|||||||
* [Clone a shallow copy of a repository](#clone-a-shallow-copy-of-a-repository)
|
* [Clone a shallow copy of a repository](#clone-a-shallow-copy-of-a-repository)
|
||||||
* [Search Commit log across all branches for given text](#search-commit-log-across-all-branches-for-given-text)
|
* [Search Commit log across all branches for given text](#search-commit-log-across-all-branches-for-given-text)
|
||||||
* [Get first commit in a branch (from master)](#get-first-commit-in-a-branch-from-master)
|
* [Get first commit in a branch (from master)](#get-first-commit-in-a-branch-from-master)
|
||||||
|
* [Unstaging Staged file](#unstaging-staged-file)
|
||||||
|
|
||||||
<!-- Don’t remove or change the comment below – that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
|
<!-- Don’t remove or change the comment below – that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
|
||||||
<!-- @doxie.inject end toc -->
|
<!-- @doxie.inject end toc -->
|
||||||
@ -846,5 +847,10 @@ git log --all --grep='<given-text>'
|
|||||||
git log master..<branch-name> --oneline | tail -1
|
git log master..<branch-name> --oneline | tail -1
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Unstaging Staged file
|
||||||
|
```sh
|
||||||
|
git reset HEAD <file-name>
|
||||||
|
```
|
||||||
|
|
||||||
<!-- Don’t remove or change the comment below – that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
|
<!-- Don’t remove or change the comment below – that can break automatic updates. More info at <http://npm.im/doxie.inject>. -->
|
||||||
<!-- @doxie.inject end -->
|
<!-- @doxie.inject end -->
|
||||||
|
@ -370,4 +370,7 @@
|
|||||||
}, {
|
}, {
|
||||||
"title": "Get first commit in a branch (from master)",
|
"title": "Get first commit in a branch (from master)",
|
||||||
"tip": "git log master..<branch-name> --oneline | tail -1"
|
"tip": "git log master..<branch-name> --oneline | tail -1"
|
||||||
|
}, {
|
||||||
|
"title":"Unstaging Staged file",
|
||||||
|
"tip": "git reset HEAD <file-name>"
|
||||||
}]
|
}]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user