git保存账号密码

  1. 进入项目目录的.git目录
  2. 使用git config --list查询当前配置
git config --list
core.repositoryformatversion=0
core.filemode=true
core.bare=false
core.logallrefupdates=true
remote.origin.url=https://e.coding.net/guoke3915/coding-demo/guoke3915.git
remote.origin.fetch=+refs/heads/*:refs/remotes/origin/*
branch.master.remote=origin
branch.master.merge=refs/heads/master
  1. 发现没有credential.helper=store
  2. 所以打开./git/config文件最后加入
[credential]
    helper = store
  1. 然后在项目中使用git pull,会输入账号密码,之后直接就不需要输入了
  2. 如果不想保存,则删除即可

你可能感兴趣的:(git保存账号密码)