I'm using vscode and git. But I don't want to publish my codes to github. VScode still keeps popping up a windows to ask me to login on github. How to disable this?
Go to File > Prefrences > Settings (ctrl + ,) and search for: gitAuthentication
Uncheck both of these settings:
This will stop the popup as well as stop prompting for a username/password when running git command from the terminal.
Alternatively, you can add these lines to your settings.json file:
{
// ...
"github.gitAuthentication": false,
"git.terminalAuthentication": false
}
While reading the link in the first comment, I saw this:
// When enabled, commits will automatically be fetched from the default remote of the current Git repository.
"git.autofetch": false,
I looked through Settings > Extensions > Git and saw Autofetch was enabled with a blue line, indicating it was not the default setting.
I reset it and now I don't get popup anymore.
The reason I was getting the popup is because my repositories are private, and the login windows aren't "saving" my login, so every 180 seconds from launch, VSCode would try to access my online gits then get denied and ask me to login for each repository again.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With