Git stash

From NovaOrdis Knowledge Base
Revision as of 00:28, 8 November 2018 by Ovidiu (talk | contribs) (Created page with "=Internal= * Git Commands =Overview= Stash the changes in a dirty working directory away. The command saves the local modificati...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Internal

Overview

Stash the changes in a dirty working directory away. The command saves the local modifications away and reverts the working directory to match the HEAD commit.

The modifications stashed away can be listed with:

git stash list
git stash show

They can be restored, potentially in top of a different commit, with:

git stash apply