From 3fe8a233c09e7c2ed1878c00f9acd34bf636aecb Mon Sep 17 00:00:00 2001 From: Diogo Lemos Date: Fri, 24 Feb 2017 11:38:44 +0000 Subject: [PATCH] Add stash all --- README.md | 17 +++++++++++++++++ tips.json | 4 ++++ 2 files changed, 21 insertions(+) diff --git a/README.md b/README.md index b7e549b..cad7841 100644 --- a/README.md +++ b/README.md @@ -52,6 +52,7 @@ P.S: All these commands are tested on `git version 2.7.4 (Apple Git-66)`. * [Saving current state of unstaged changes to tracked files](#saving-current-state-of-unstaged-changes-to-tracked-files) * [Saving current state including untracked files](#saving-current-state-including-untracked-files) * [Saving current state with message](#saving-current-state-with-message) +* [Saving current state of all files (ignored, untracked, and tracked)](#saving-current-state-of-all-files-ignored-untracked-and-tracked) * [Show list of all saved stashes](#show-list-of-all-saved-stashes) * [Apply any stash without deleting from the stashed list](#apply-any-stash-without-deleting-from-the-stashed-list) * [Apply last stashed state and delete it from stashed list](#apply-last-stashed-state-and-delete-it-from-stashed-list) @@ -439,6 +440,22 @@ git stash save --include-untracked git stash save ``` +## Saving current state of all files (ignored, untracked, and tracked) +```sh +git stash -a +``` + + +__Alternatives:__ +```sh +git stash --all +``` + + +```sh +git stash save --all +``` + ## Show list of all saved stashes ```sh git stash list diff --git a/tips.json b/tips.json index ab99a12..2693d2b 100644 --- a/tips.json +++ b/tips.json @@ -131,6 +131,10 @@ }, { "title": "Saving current state with message", "tip": "git stash save " +}, { + "title": "Saving current state of all files (ignored, untracked, and tracked)", + "tip": "git stash -a", + "alternatives": ["git stash --all", "git stash save --all"] }, { "title": "Show list of all saved stashes", "tip": "git stash list"