You can pass a commit hash to checkout to quickly see a previous version of code. I like to commit often as I get new chunks of partial code working. If I advance to the point of breaking everything, it’s an easy way to see what used to work.
git checkout <commit hash>
In playing with getting git’s credential helper to work on Windows, I accidentally added multiple helpers to my local config file. It took me a while to figure out where it was stored and how to reset it. I used this command when in the local repo directory.
git config --unset-all credential.helper This Stack Overflow post got me close but was based on the multiple values coming from different versions of the config file.