Create a git lg alias
git config --global alias.lg "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --"
git config --local user.name <username>
git config --local user.email <email>
git lg
git rebase -i <commit-number>
- Replace pick with d or drop. Save your changes & close the editor.
git push --force-with-lease
git restore <filename>