banner



How To Remove Git Password From Windows

ConfigCat profile image david-zoltan

Lazy man'south guide: multiple GitHub HTTPS accounts on Windows

Using multiple GitHub account's on Windows sucks by default. If you are tired of Window's Credential Manager storing but one account'due south credential for git:https://github.com then hither is a one-minute fix for you lot.

TL;DR

If y'all know what you're doing just:

  • delete your GitHub credentials from Windows Credential Manager
  • run git config --global credential.github.com.useHttpPath true
  • go along coding

If you need more than detailed instructions and learn nigh the background just read on.

The full story

I'1000 juggling with multiple GitHub repos on a daily basis. They all require unlike credentials. It'southward non only the repos of ConfigCat, my feature flag service (a groovy LaunchDarkly alternative "by the way") but my other projects also. If you're a developer at heart, I'g certain you know what I'm talking about. I never actually liked how the credential manager on Windows stores one single GitHub account for all my repos by default.

Just came through @arnellebalane 'due south great post about setting up multiple GitHub accounts the prissy fashion. His solution is based on SSH keys and is pretty thorough.

While I would never publicly admit that I'm lazy, I happen to know a quick and dirty solution here. I decided to share the "lazy human being's guide" to set upwards multiple GitHub accounts on Windows. While @arnellebalane 's solution is really prissy, you might be interested in a more than basic arroyo...

The problem

If you're using Windows Credential Manager to shop your username/password for your GitHub account, and you have to work with different GitHub accounts for different projects, then I'yard sure you've already experienced

            fatal: Authentication failed for https://www.github.com/name/repo.git                      

Usually, this happens when you try to push to 1 of your repositories in the name of another business relationship that is for your other project.

The root problem is that Windows Credential stores the one same account for all your GitHub repositories.

The solution

There is a simple, three steps solution that will help you shop multiple different GitHub accounts, one for each of your GitHub repos.

Simple 3 step solution:

  • remove your electric current GitHub credentials from Windows Credential Manager
  • tell Windows to store different accounts for each of your GitHub repos
  • provide your username, password once over again for each repo when y'all are prompted for your credentials - this is the last time you need to practice that

Removing current GitHub credentials from Windows Credential Managing director

Go to Windows Credential Managing director, open the Windows Credentials tab, locate git:https://github.com, open the entry, and click Remove.

Windows Credential Manager

This will remove your GitHub credentials from the credential manager.

Tell Windows to shop different accounts for different repos

Upshot the following git command:

            git config --global credential.github.com.useHttpPath true                      

Now, Windows will shop dissimilar logins for each of your GitHub repos.

Reauthenticate

Only piece of work on your projection. Whenever GitHub asks you for your credentials, just type your username and password. Windows will store them and you lot never ever accept to provide them again for this repo.

Source: https://dev.to/configcat/lazy-man-s-guide-multiple-github-https-accounts-on-windows-2mad

Posted by: owensthatimed.blogspot.com

0 Response to "How To Remove Git Password From Windows"

Post a Comment

Iklan Atas Artikel

Iklan Tengah Artikel 1

Iklan Tengah Artikel 2

Iklan Bawah Artikel