解决github每次pull push输入密码问题

# 解决git pull/push每次都需要输入密码问题

git bash进入你的项目目录,输入:

bash 复制代码
git config --global credential.helper store

然后你会在你本地生成一个文本,上边记录你的账号和密码。配置项写入到 "C:\Users\用户名\ .gitconfig" 文件中。

然后你使用上述的命令配置好之后,再操作一次git pull,然后它会提示你输入账号密码,这一次之后就不需要再次输入密码了。

此外,相关操作
git config credential.helper 记住保存账号密码、关闭取消密码自动存储

取消(删除)记录账号和密码

bash 复制代码
git config --global --unset credential.helper

查询 凭证存储模式

bash 复制代码
git config --global credential.helper
或
git config --global --list
或
git config --global -l

修改 配置文件

bash 复制代码
git config --file=~/.git_credentails --global credential.helper "store"
或
git config --global  user.name "store"
相关推荐
用户383170370544 小时前
PowerFS 是用 Rust 写的、面向 AI/GPU 训练的下一代分布式文件系统
github
钮钴禄·爱因斯晨4 小时前
用iPhone操作Codex CLI:ToDesk远程终端让我接回了开发环境
github
miofly6 小时前
GitHub 日榜趋势速报 | 2026-10-01
开源·github
阿里嘎多学长7 小时前
2026-09-30 GitHub 热点项目精选
开发语言·程序员·github·代码托管
miofly18 小时前
GitHub 今日推荐|DiPlay:让 iPhone CarPlay 直连 BYD 车机,无需硬件适配器
开源·github
行者-全栈开发19 小时前
【前端/JS框架】CVE-2026-3854:GitHub Enterprise Server X-Stat注入XSS漏洞深度剖析与紧急修复指南
前端·javascript·github
怕浪猫20 小时前
2026年9月面18个后端
后端·面试·github
掘金011 天前
Cursor Agent Prompt 拆解
人工智能·程序员·github
樱花落木兰1 天前
SpringBoot + ECharts 后台数据统计报表模块实战
java·javascript·spring boot·ai·log4j·github·echarts