1
0
mirror of https://github.com/namibia/tips.git synced 2024-12-22 10:08:58 +00:00

Merge pull request #143 from eliranmal/master

add change by content search tip
This commit is contained in:
hemanth.hm 2017-03-23 18:48:08 +05:30 committed by GitHub
commit 77c865cedf
2 changed files with 9 additions and 0 deletions

View File

@ -13,6 +13,7 @@ P.S: All these commands are tested on `git version 2.7.4 (Apple Git-66)`.
<!-- Dont remove or change the comment above that can break automatic updates. -->
* [Everyday Git in twenty commands or so](#everyday-git-in-twenty-commands-or-so)
* [Show helpful guides that come with Git](#show-helpful-guides-that-come-with-git)
* [Search change by content](#search-change-by-content)
* [Overwrite pull](#overwrite-pull)
* [List of all files till a commit](#list-of-all-files-till-a-commit)
* [Git reset first commit](#git-reset-first-commit)
@ -179,6 +180,11 @@ git help everyday
git help -g
```
## Search change by content
```sh
git log -S'<a term in the source>'
```
## Overwrite pull
```sh
git fetch origin && git reset --hard origin/master

View File

@ -4,6 +4,9 @@
}, {
"title": "Show helpful guides that come with Git",
"tip": "git help -g"
}, {
"title": "Search change by content",
"tip": "git log -S'<a term in the source>'"
}, {
"title": "Overwrite pull",
"tip": "git fetch origin && git reset --hard origin/master"