forked from lcp0578/cheat-sheets
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
53 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,15 @@ | ||
## git ssh | ||
有时,我们会修改ssh的默认端口号,那么我们在使用git clone git@gitee.com:lcp0578/test会失败。 | ||
需要修改配置项: | ||
- 生成SSH Key | ||
|
||
cat>~/.ssh/config | ||
# 映射一个别名 | ||
host gitee.com | ||
hostname gitee.com | ||
port 22 | ||
$ ssh-keygen -t rsa -C "lcp0578@gmail.com" | ||
- 获取SSH Key | ||
|
||
$ cat id_rsa.pub | ||
- 有时,我们会修改ssh的默认端口号,那么我们在使用git clone git@gitee.com:lcp0578/test会失败。 | ||
需要修改配置项: | ||
|
||
cat>~/.ssh/config | ||
# 映射一个别名 | ||
host gitee.com | ||
hostname gitee.com | ||
port 22 |