2

How do I make powershell stop showing the below message:

github --credentials get: github: command not found

This occurs whenever I try to ssh for git push or git pull.

jrbedard
  • 3,662
  • 5
  • 30
  • 34
Hongyu Wang
  • 378
  • 1
  • 10

1 Answers1

1

Check you git remote -v: it you see https, it is not an ssh url.
Make sure push or pull are using an ssh url with:

git remote set-url origin git@github.com:username/repo.git

If you are using https, Git will try and use a credential helper: see if git config -l | grep cred returns anything. That would explain the github: command not found part.

If you have, go to your repo and type:

cd /path/to/my/repo
git config credential.helper ""

If your git is recent enough (Git 2.9+), that will prevent any credential helper to be active in your repo.

Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250