Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in DevOps and Agile by (19.7k points)

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.

1 Answer

0 votes
by (62.9k points)

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

Related questions

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
asked Jul 12, 2019 in DevOps and Agile by chandra (29.3k points)
+6 votes
2 answers

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...