git 操作总是输入用户名密码

 
            记录一下,省的总是找,屡试不爽
            方案一,使用sshKey
                生成公钥 $ ssh-keygen -t rsa -C "xxxx@xxxx.com"

            方案二,设置全局name、email、password 
               $ git config --global user.name "xxxxxxxxx"
               $ git config --global user.email "xxxxx@xxx.com"
               $ git config --global user.password "xxxxxxxxx"

            方案二补充,若还是不行,在项目目录下执行
               $ git config --global credential.helper store
posted @ 2020-09-10 10:50  南巷清风--大R  阅读(175)  评论(0)    收藏  举报