I made a mistake and mispelt the name of my .gitignore file and when I went to push up to Github I realised I was also pushing up everything in my node_modules
directory. I cancelled the command (ctrl + c) and fixed the .gitignore and ran git rm -r --cached .
.
Running git status
then showed only the changes to my .gitignore file so I commited them and then when to push up. However, during the git push
I noticed the node_module
files were still being pushed up.
Again I cancelled the command (ctrl + c) and ran git reset --hard HEAD^
, re-added and re-committed, but again it seemed I was pushing up the node_module
files.
Becuase I cancelled the push part-way through these files seem to be stuck in limbo.
Is there some way I can fix this so I can merge to github without pushing up my node_module
files?