錯(cuò)誤信息如下:
git push -u origin master
remote: HTTP Basic: Access denied
fatal: Authentication failed for 'https://git.nowcoder.com/7543696/MyFirstSSM.git/'
對(duì)于這種錯(cuò)誤信息,首先應(yīng)該設(shè)置git的密碼躬贡,點(diǎn)擊Git賬號(hào)設(shè)置
image.png
image.png
如果沒(méi)有設(shè)置過(guò)密碼谆奥,則需要先設(shè)置密碼,設(shè)置成功后
在git的終端中輸入
git config --system --unset credential.helper
或者
git config –global http.emptyAuth true
我使用了第二個(gè)命令成功的拂玻,再次輸入
git push -u origin master
輸入名字和并在彈出框中輸入剛剛設(shè)置的密碼即可上傳成功酸些。
Username for 'https://git.nowcoder.com':