zoukankan      html  css  js  c++  java
  • git--config

    1 设置用户

     

    1.1 全局用户

     

    1.1.1 设置姓名、邮箱

    git config --global user.name "你的账号名称"
    git config --global user.email "你的邮箱"
    

    1.1.2 生成 SSH key 文件

    一路回车,使用默认值即可

    ssh-keygen -t rsa -C "你的邮箱"
    

    1.1.3 添加 key 到 github 账号上

     
    1. 到对应路径中拷贝刚生成的 xxx.pub 文件中的内容(一个字符串)
    2. 登录 github 账号,点击 头像->Settings->SSH and GPG keys-> New SSH key
    3. Title 任意,Key 中粘贴上拷贝的字符串,确认(可能需要输入密码确认)

    1.1.4 连接测试

    ssh -T git@github.com
    
    1. 成功提示

      Hi 你的账号名称! You've successfully authenticated, but GitHub does not provide shell access.

    2. 连接出错
      1. Permission denied
        1. 错误提示(类似下面这样子的)

          Permissions 0670 for 'home/12131.ssh/idrsa' are too open. It is recommended that your private key files are NOT accessible by others. This private key will be ignored. Load key "home/12131.ssh/idrsa": bad permissions Permission denied (publickey).

        2. 通过设置权限解决
          chmod 755 ~/.ssh/
          chmod 600 ~/.ssh/id_rsa ~/.ssh/id_rsa.pub
          chmod 644 ~/.ssh/known_hosts
          

    Created: 2019-12-10 周二 16:22

    Validate

  • 相关阅读:
    Linux虚拟内存管理(glibc)
    linux kernel内存回收机制
    Linux的Cache Memory(缓存内存)机制
    imx6用文件io操作gpio
    imx6中iomux IO复用
    start with git
    Linux进程的虚拟内存区域划分
    关于函数返回值为指针类型的分析
    对LCD接口的认识
    LCD屏背光驱动调试心得---血的教训
  • 原文地址:https://www.cnblogs.com/heidekeyi/p/12017427.html
Copyright © 2011-2022 走看看