撤消一个git存储 [英] Undo a git stash

查看:90
本文介绍了撤消一个git存储的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我只是藏在一个我没有犯下的项目中。我藏起来之前有没有办法回到这个状态?我怎么能这样做?我已关闭终端,笔记本电脑已关闭。我已经做了一些调查,看起来没有办法做到这一点。

  git stash pop 



<如果你想保存文件的状态(staged vs. working),使用

  git stash apply --index 


I just did a stash in a project that I haven't commit. Is there a way to go back to the state before I stashed? How could I do this? I've closed the terminal and my laptop is shut down. I've done some researched and it seems there's no way to do this.

解决方案

You can just run:

git stash pop

and it will unstash your changes.

If you want to preserve the state of files (staged vs. working), use

git stash apply --index

这篇关于撤消一个git存储的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆