OSDN Git Service

feat(intro/faq.md): add speed up via FastGit
authorCoelacanthus <coelacanthus@outlook.com>
Wed, 27 Jan 2021 05:52:02 +0000 (13:52 +0800)
committerCoelacanthus <coelacanthus@outlook.com>
Wed, 27 Jan 2021 05:52:02 +0000 (13:52 +0800)
[1]: https://fastgit.org/
[2]: https://doc.fastgit.org/zh-cn/guide.html
[3]: https://github.com/OI-wiki/OI-wiki/pull/2915#issuecomment-768036382

docs/intro/faq.md

index 4ba53e5..10dbb64 100644 (file)
@@ -100,6 +100,18 @@ A:推荐在 hosts 文件中加入如下几行[^ref1]:
 
 Linux 和 macOS 用户可以尝试使用[依云](https://github.com/lilydjwg/)的 [gh-check 脚本](https://gist.github.com/lilydjwg/93d33ed04547e1b9f7a86b64ef2ed058)获取访问最快的 IP,使用 `--hosts` 参数可以直接更新 hosts 文件。使用 `--help` 参数可以获取使用帮助。使用先需要安装 Python3 和 aiohttp (`pip install aiohttp -i https://pypi.tuna.tsinghua.edu.cn/simple/`)。依云博客的介绍:[寻找最快的 GitHub IP](https://blog.lilydjwg.me/2019/8/16/gh-check.214730.html)。
 
+同时,您可以使用 [FastGit](https://fastgit.org/) 服务加速 Clone,可以阅读其[使用文档](https://doc.fastgit.org/zh-cn/guide.html)。
+
+如果您仅仅是想 Clone OI Wiki 的仓库,那么:
+```bash
+git clone https://hub.fastgit.org/OI-wiki/OI-wiki.git
+```
+如果您需要向 OI Wiki 贡献,那么首先 fork OI Wiki 的仓库,然后(将 `username` 替换为您的用户名),需要注意的是提供的示例将使您使用 SSH 连接到 GitHub[^only-ssh-connect]:
+```bash
+git clone https://hub.fastgit.org/username/OI-wiki.git
+git remote set-url origin git@github.com:username/OI-wiki.git
+```
+
 * * *
 
 Q:我这里 pip 也太慢了
@@ -267,3 +279,5 @@ A: `_redirects` 文件用于生成 [netlify 的配置](https://docs.netlify.co
 [^ref3]:  [GIT--- 看我一步步入门(Windows Git Bash)](https://blog.csdn.net/FreeApe/article/details/46845555) 
 
 [^ref4]:  [Metadata - Material for MkDocs](https://squidfunk.github.io/mkdocs-material/extensions/metadata/#usage) 
+
+[^only-ssh-connect]: GitHub 弃用了基于密码身份验证的 HTTPS 协议,连接必须使用 SSH 或者 Personal Access Token,参见[我应使用哪个远程 URL?](https://docs.github.com/cn/github/using-git/which-remote-url-should-i-use),[创建个人访问令牌](https://docs.github.com/cn/github/authenticating-to-github/creating-a-personal-access-token)和[使用 SSH 连接到 GitHub](https://docs.github.com/cn/github/authenticating-to-github/connecting-to-github-with-ssh)。