zoukankan      html  css  js  c++  java
  • git不用输入账户密码

     
    1.1 创建文件存储GIT用户名和密码

    在%HOME%目录中,一般为C:usersAdministrator,(linux下选择~目录)也可以是你自己创建的系统用户名目录,反正都在C:users中。文件名为.git-credentials,由于在Window中不允许直接创建以"."开头的文件,所以需要借助git bash进行,打开git bash客户端,进行%HOME%目录,然后用touch创建文件 .git-credentials, 用vim编辑此文件,输入内容格式:

    touch .git-credentials

    vim .git-credentials

    https://{username}:{password}@github.com

    1.2 添加Git Config 内容

    进入git bash终端, 输入如下命令:

    git config --global credential.helper store

    执行完后查看%HOME%目录下的.gitconfig文件,会多了一项:

    [credential]

        helper = store 
  • 相关阅读:
    滑雪(dp好题)
    田忌赛马
    反质数(Antiprimes)
    LCA-倍增法(在线)
    二模 (2) day2
    Spring Integration
    [转载] Spring MVC
    收藏夹
    Linux profile File
    git merge 与 rebase 的区别
  • 原文地址:https://www.cnblogs.com/govoid/p/4995061.html
Copyright © 2011-2022 走看看