Actually undo git stash pop

前端 未结 4 2103
迷失自我
迷失自我 2021-02-13 15:16

This question had the same title but it is NOT the same question. That question is really asking \"Discard results of git stash pop\". This question is actually

4条回答
  •  闹比i
    闹比i (楼主)
    2021-02-13 15:19

    You can reverse patch the stash (which as already mentioned should still be there as git wont drop a stash if it doesn't apply cleanly)

    git stash show -p stash@{0} | git apply -R
    

提交回复
热议问题