Chinaunix首页 | 论坛 | 博客
  • 博客访问: 2385037
  • 博文数量: 328
  • 博客积分: 4302
  • 博客等级: 上校
  • 技术积分: 5486
  • 用 户 组: 普通用户
  • 注册时间: 2010-07-01 11:14
个人简介

悲剧,绝对的悲剧,悲剧中的悲剧。

文章分类

全部博文(328)

文章存档

2017年(6)

2016年(18)

2015年(28)

2014年(73)

2013年(62)

2012年(58)

2011年(55)

2010年(28)

分类: 系统运维

2016-03-08 00:41:52

Entering the passphrase is annoying when using git commands, and even worse if you need to establish some automation scripts. Here are some methods to solve this issue.


Adding your SSH key to the ssh-agent


  • Ensure ssh-agent is enabled:

    # start the ssh-agent in the background eval "$(ssh-agent -s)" Agent pid 59566 
  • Add your SSH key to the ssh-agent:

    ssh-add ~/.ssh/id_rsa 


  • Other methods:


    ssh-add ~/.ssh/id_rsa &>/dev/null

    Or try this on OS X?

    • git config --global credential.helper osxkeychain 

    It enables git to use Keychain.app to store username and password and to retrieve the passphrase to your private ssh key from the keychain.

    For windows use:

    • git config --global credential.helper wincred

    阅读(1262) | 评论(0) | 转发(0) |
    给主人留下些什么吧!~~