![]() ![]() Like pop, but do not remove the state from the stash list. You need to resolve the conflictsīy hand and call git stash drop manually afterwards. The working directory must match the index.Īpplying the state can fail with conflicts in this case, it is not removed from the stash list. Remove a single stashed state from the stash list and apply it on top of the current working tree state, i.e., do the inverse You can use stash.showStat and/or stash.showPatch config variables By default, the command shows the diffstat, but it will accept any format known to git diff (e.g., git stash show to view the second most recent entry in patch form). Show the changes recorded in the stash entry as a diff between the stashed contents and the commit back when the stash entry wasįirst created. The command takes options applicable to the git log command to control what is shown and how. ![]() is the latest is the one before, etc.), the name of the branch that was current when the entry was made, and a short description of theĬommit the entry was based WIP on submit: 6ebd0e2. Each stash entry is listed with its name (e.g. List the stash entries that you currently have. It is probably not the command you want to use see "push" above. This is intended to be useful for scripts. Store a given stash created via git stash create (which is a dangling merge commit) in the stash ref, updating the stash reflog. Non-option arguments are concatenated to form the stash message. It differs from "stash push" in that it cannot take pathspec. This option is deprecated in favour of git stash push. Pathspec elements, which are allowed after a double hyphen - for disambiguation. The two exceptions to this are stash -p which acts as alias for stash push -p and Subcommand from making an unwanted stash entry. In this mode, non-option arguments are not allowed to prevent a misspelled Part is optional and gives the description along with the stashed state.įor quickly making a snapshot, you can omit "push". ![]() Save your local modifications to a new stash entry and roll them back to HEAD (in the working tree and in the index). the integer n is equivalent to keep-index] Stashes may also be referenced by specifying just the stash index (e.g. is the most recently created stash, is the one before it, is also The latest stash you created is stored in refs/stash older stashes are found in the reflog of this reference and can be named using ", but you can give a more descriptive message on the command line when you A stash is by default listed as "WIP on branchname. Calling git stash without any arguments is equivalent to git stash (potentially on top of a different commit) with git stash apply. The modifications stashed away by this command can be listed with git stash list, inspected with git stash show, and restored The command saves your local modifications away and reverts the working directory to match the HEAD commit. Use git stash when you want to record the current state of the working directory and the index, but want to go back to a clean workingĭirectory. Git-stash - Stash the changes in a dirty working directory away ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |