I use BitBucket and had to change my password because it was compromised.
git pull
remote: Invalid username or password. If
I needed to do this and run a git pull in order to set my password from the command line in order to get this working.
Note this method saves your password in a plain text file on your disk:
git config --global credential.helper store
git pull
Other solutions here: Is there a way to skip password typing when using https:// on GitHub?