Get back the changes after accidental checkout?
Posted
by Millisami
on Stack Overflow
See other posts from Stack Overflow
or by Millisami
Published on 2010-06-02T20:11:24Z
Indexed on
2010/06/02
20:14 UTC
Read the original article
Hit count: 229
git
|git-checkout
The following was the status of my repo.
[~/rails_apps/jekyll_apps/nepalonrails (design)?] ? gst
# On branch design
# Changed but not updated:
# (use "git add/rm <file>..." to update what will be committed)
# (use "git checkout -- <file>..." to discard changes in working directory)
#
# modified: _layouts/default.html
# deleted: _site/blog/2010/04/07/welcome-to-niraj-blog/index.html
# deleted: _site/blog/2010/04/08/the-code-syntax-highlight/index.html
# deleted: _site/blog/2010/05/01/showing-demo-to-kalyan/index.html
# deleted: _site/config.ru
# deleted: _site/index.html
# deleted: _site/static/css/style.css
# deleted: _site/static/css/syntax.css
# modified: static/css/style.css
#
no changes added to commit (use "git add" and/or "git commit -a")
Accedently, I did git checkout -f
and now the changes are gone which I wasnt supposed to do.
[~/rails_apps/jekyll_apps/nepalonrails (design)?] ? git co -f
[~/rails_apps/jekyll_apps/nepalonrails (design)] ? gst
# On branch design
nothing to commit (working directory clean)
[~/rails_apps/jekyll_apps/nepalonrails (design)] ?
Can I get back the changes back?
© Stack Overflow or respective owner