summaryrefslogtreecommitdiff
path: root/Documentation
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/git-stash.txt15
1 files changed, 8 insertions, 7 deletions
diff --git a/Documentation/git-stash.txt b/Documentation/git-stash.txt
index 8f331ee7d4..e2c8722376 100644
--- a/Documentation/git-stash.txt
+++ b/Documentation/git-stash.txt
@@ -180,13 +180,14 @@ each change before committing:
+
----------------------------------------------------------------
... hack hack hack ...
-$ git add --patch foo
-$ git stash save --keep-index
-$ build && run tests
-$ git commit -m 'First part'
-$ git stash apply
-$ build && run tests
-$ git commit -a -m 'Second part'
+$ git add --patch foo # add just first part to the index
+$ git stash save --keep-index # save all other changes to the stash
+$ edit/build/test first part
+$ git commit foo -m 'First part' # commit fully tested change
+$ git stash pop # prepare to work on all other changes
+... repeat above five steps until one commit remains ...
+$ edit/build/test remaining parts
+$ git commit foo -m 'Remaining parts'
----------------------------------------------------------------
SEE ALSO