dev-aid/git/ssh-key.md
2023-02-10 09:35:46 +08:00

23 lines
334 B
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<h1>
Git
<h3>生成 SSH 密钥</h3>
</h1>
### 先执行以下语句来判断是否已经存在本地公钥:
```sh
cat ~/.ssh/id_rsa.pub
```
### 你可以按如下命令来生成 ssh key
```bash
ssh-keygen -t rsa -C "service@yinghuainfo.com"
```
### 用以下命令获取你生成的公钥
```bash
cat ~/.ssh/id_rsa.pub
```