aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorjohannst <johannes.stoelp@gmail.com>2020-03-19 20:07:07 +0100
committerjohannst <johannes.stoelp@gmail.com>2020-03-19 20:07:07 +0100
commit70883a31c72d9427055b41ca50ba986cd808cde4 (patch)
tree2e378ef7cd5c33cbc62a23c8d5a3d0506f91868c
parented2be86b970350be0b6aa8f18b63a313f3c76983 (diff)
downloadnotes-70883a31c72d9427055b41ca50ba986cd808cde4.tar.gz
notes-70883a31c72d9427055b41ca50ba986cd808cde4.zip
updated git
-rw-r--r--src/git.md11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/git.md b/src/git.md
index 47c99e4..d76ae77 100644
--- a/src/git.md
+++ b/src/git.md
@@ -60,7 +60,12 @@
'--pretty=oneline --abbrev-commit'
git log --graph ...... text based graph of commit history
git log --decorate ... decorate log with REFs
- git log -p <file> .... show commit history + diffs for <file>
+```
+
+## File history
+```markdown
+ git log -p <file> ......... show commit history + diffs for <file>
+ git log --oneline <file> .. show commit history for <file> in compact format
```
## Patching
@@ -74,7 +79,7 @@
number instead '1'
since spcifier:
-3 .................. e.g: create a patch from last three commits
- <comit hash> ........ create patch with commits starting after <comit hash>
+ <commit hash> ....... create patch with commits starting after <commit hash>
git am <patch> ......... apply patch and create a commit for it
@@ -103,6 +108,8 @@
<submod>, this will pull
origin/HEAD or a branch specified
for the submodule
+ git diff --submodule ...................... show commits that are part of the
+ submodule diff
```
## Inspection