I had a old project which I wanted to add git to. I run
git init
and after that I added .gitignore file. The error I did is that I haven't commit anything first but I wanted to see if my gitignore file works so I run
git add .
I noticed that there are more files I wanted to exclude (whole project is 45GB with assets) so I run
git reset --hard
and this mess up my whole repo. I lost all of the files except the ones listed in gitignore and I cannot do anything.
git status
shows me a files listed in git ignore and if I run
git reflog
or even
git log
I have this error
fatal: your current branch 'master' does not have any commits yet
Please let me know how can I restore my project?