From 58c6d98940ca322bfe91d8ae6c8fc3e988347513 Mon Sep 17 00:00:00 2001 From: Johannes Stoelp Date: Sun, 20 Mar 2022 21:58:51 +0100 Subject: git: added working areas + file at specific commit --- src/tools/git.md | 33 ++++++++++++++++++++++++++++++++- 1 file changed, 32 insertions(+), 1 deletion(-) diff --git a/src/tools/git.md b/src/tools/git.md index a626eae..7262ba4 100644 --- a/src/tools/git.md +++ b/src/tools/git.md @@ -1,6 +1,35 @@ # git(1) -## staging +## Working areas +```text ++-------------------+ --- stash -----> +-------+ +| working directory | | stash | // Shelving area. ++-------------------+ <-- stash pop -- +-------+ + | ^ + add | + | reset + v | ++-------------------+ +| staging area | ++-------------------+ + | + commit + | + v ++-------------------+ +| local repository | ++-------------------+ + | ^ + push | + | fetch / + | pull + v | ++-------------------+ +| remote repository | ++-------------------+ +``` + +## Staging ```markdown git add -p [] ............ partial staging (interactive) ``` @@ -67,6 +96,8 @@ git show --stat ................ show files changed by git show [] .............. show diffs for + + git git show : ............ show at ``` ## Patching -- cgit v1.2.3