Shengting Cao's Notebook ᕦʕ •ᴥ•ʔᕤ

GitHub New Security Config

GitHub has recently upgraded its authentication protocol, shifting from a password-based approach to a more secure token-based system. While this update certainly boosts repository security, it does come with a slight trade-off in terms of convenience. I’ve taken some notes on how to adapt to these changes on GitHub:

The first step is to request a token directly from GitHub. Instead of inputting your password when pushing code, you should now employ this token as your GitHub account password.

Additionally, to streamline the process of pulling and pushing code, you can configure your local environment to remember your username and email. This small adjustment can significantly enhance the speed and efficiency of your interactions with GitHub.

git config --global user.name " "

git cofig --global user.email " "

git config -l

After you clone or push the repository using the tocken you can use the

git config --global credential.helper cache

to remember the token

You can clear the tocken by using

git config --global --unset credential.helper

#GitHub