I saw this sentence in the official Github help manual:
When you
git clone
,git fetch
,git pull
, orgit push
to a remote repository using HTTPS URLs on the command line, you' ll be asked for your GitHub username and password.
When you use the HTTPS URL in the command line to performgit clone
,git fetch
,git pull
, orgit push
operations on the remote repository , you will be asked to enter your Github username and password.
But in fact, I have never encountered a requirement to enter a username and password in git clone
(using the http protocol). Is it because the help document is written incorrectly?
NOTE:This question originated from another question on this site. I suddenly thought of this question when I was answering other people's questions.
It is very likely that you have entered it before
Because I have encountered it before and had to enter the account number and password
I don’t know what the situation is on your side
I didn’t enter it again when I submitted it
If the project is open source, you do not need to enter the username or password when executing
git clone
. You will only be asked to enter the account password when submitting the code after modifying the project.