git rm --cached filename
git rm -r --cached . git add . git commit -m ".gitignore is now working"
git remote -v
set the new URL (for example, [email protected]:User/project-new.git)
git remote set-url origin [email protected]:User/project-new.git
git reset
- --soft HEAD~1: back to staging
- (default) --mixed HEAD~1: back to working tree
- --hard HEAD~1: back to the beginning, working tree clean
git log git log --oneline (-n3)