---
title: "如何避免git每次提交都输入密码"
author: "ChinaEstone"
date: "2014-08-07T13:12:39Z"
tags: []
categories: ["开源软件"]
slug: "git"
draft: false
lastmod: "2014-08-07T13:14:57Z"
id: 2101298
url: "https://chinaestone.iteye.com/blog/2101298"
---

```
vim /home/chinaestone/.git-credentials

输入内容
https://{username}:{password}@github.com

保存退出后执行下面命令
git config --global credential.helper store

执行完后
/home/chinaestone/.gitconfig 会新增一项
 helper = store
这是再执行git push/pull的时候就不会在要求你输入密码了。别问我
为什么不用ssh？没有为什么，就是不用。
```