看来,当我执行 git stash apply 时,我需要输入 git stash drop 以便从可用的存储中删除该存储。我可以在一个命令中执行此操作吗?
问问题
108 次
1 回答
7
git stash pop
就是你要找的。正如手册页所说:
pop [--index] [-q|--quiet] [<stash>]
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 operation
of git stash save. The working directory must match the index.
Applying the state can fail with conflicts; in this case, it is not
removed from the stash list. You need to resolve the conflicts by hand
and call git stash drop manually afterwards.
于 2012-07-05T20:06:04.167 回答