Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Yes there is. When you have a new repository without any commits, there is no HEAD, so you can't unstage by resetting.

    mkdir try
    cd try
    git init
    touch file
    git add file
    git status
Still, the git status command shows you what you need to do to unstage.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: