git: 'credential-cache' is not a git command - Remove setting

I ran git config --global -e but it did not contain any sections related to credentials.

However, when I ran git config -e I did find there was a [credential] section.

The following command resolved the issue for me.

git config --remove-section credential


Running git config --global -e allowed me to remove the offending config setting from the global git config.

[credential]
helper = winstore

I had same problem with error:

$ git push -u origin master
git: 'credential-cache' is not a git command. See 'git --help'.
Branch master set up to track remote branch master from origin.
Everything up-to-date

So I decided to get rid of credential caching altogether, and I did it with in Git bash:

git config --global -e

then I found

[credential]
    helper = cache

and deleted it, saved file and after I tried again result was:

$ git push
Everything up-to-date

So error gone away.