Git, how to generate public key

前端 未结 3 1442
梦谈多话
梦谈多话 2020-12-13 01:15

how to generate a public key(to be used in GitHub/GitLab) using command line [Git Bash].

The command below generates the error sh.exe\": syntax error near une

3条回答
  •  长情又很酷
    2020-12-13 01:41

    The command to run is only

    ssh-keygen -t rsa -C "you@example.com"
    

    All the rest beginning with line 2 of your script is the output of ssh-keygen.

    And replace you@example.com with your email address.

    Have a look at the manual for ssh-keygen to look for additional options. You should probably use a longer key by adding -b 4096 to the option list.

提交回复
热议问题