Skip to content

Commit e43029a

Browse files
authored
New translation batch for cn (#32291)
1 parent 0260167 commit e43029a

File tree

157 files changed

+369
-4608
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

157 files changed

+369
-4608
lines changed

translations/log/msft-cn-resets.csv

Lines changed: 124 additions & 26 deletions
Large diffs are not rendered by default.
Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
2-
title: About SSH
3-
intro: 'Using the SSH protocol, you can connect and authenticate to remote servers and services. With SSH keys, you can connect to {% data variables.product.product_name %} without supplying your username and {% data variables.product.pat_generic %} at each visit.{% ifversion ssh-commit-verification %} You can also use an SSH key to sign commits.{% endif %}'
2+
title: 关于 SSH
3+
intro: '使用 SSH 协议可以连接远程服务器和服务并向它们验证。 利用 SSH 密钥可以连接到 {% data variables.product.product_name %},而无需在每次访问时都提供用户名和 {% data variables.product.pat_generic %}{% ifversion ssh-commit-verification %}还可以使用 SSH 密钥对提交进行签名。{% endif %}'
44
redirect_from:
55
- /articles/about-ssh
66
- /github/authenticating-to-github/about-ssh
@@ -12,27 +12,29 @@ versions:
1212
ghec: '*'
1313
topics:
1414
- SSH
15+
ms.openlocfilehash: 51a72821217e5d47092ed77e923b38f4cf248010
16+
ms.sourcegitcommit: a0ad3bfe2a99c3092e76ca9b3d476cf30988ca55
17+
ms.translationtype: HT
18+
ms.contentlocale: zh-CN
19+
ms.lasthandoff: 10/28/2022
20+
ms.locfileid: '148118977'
1521
---
22+
{% data reusables.ssh.about-ssh %} 有关 SSH 的详细信息,请参阅 Wikipedia 上的[安全外壳](https://en.wikipedia.org/wiki/Secure_Shell)
1623

17-
{% data reusables.ssh.about-ssh %} For more information about SSH, see [Secure Shell](https://en.wikipedia.org/wiki/Secure_Shell) on Wikipedia.
24+
设置 SSH 时,需要生成新的 SSH 私钥并将其添加到 SSH 代理中。 使用密钥进行身份验证{% ifversion ssh-commit-verification %}或对提交进行签名{% endif %}之前,还必须将 SSH 公钥添加到 {% data variables.product.product_name %} 上的帐户中。 有关详细信息,请参阅“[生成新的 SSH 密钥并将其添加到 ssh-agent](/authentication/connecting-to-github-with-ssh/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent)”{% ifversion ssh-commit-verification %}、{% else %}和{% endif %}“[将新的 SSH 密钥添加到 {% data variables.product.prodname_dotcom %} 帐户](/authentication/connecting-to-github-with-ssh/adding-a-new-ssh-key-to-your-github-account)”{% ifversion ssh-commit-verification %}和“[关于提交签名验证](/articles/about-commit-signature-verification){% endif %}”。
1825

19-
When you set up SSH, you will need to generate a new private SSH key and add it to the SSH agent. You must also add the public SSH key to your account on {% data variables.product.product_name %} before you use the key to authenticate{% ifversion ssh-commit-verification %} or sign commits{% endif %}. For more information, see "[Generating a new SSH key and adding it to the ssh-agent](/authentication/connecting-to-github-with-ssh/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent)"{% ifversion ssh-commit-verification %}, {% else %} and{% endif %} "[Adding a new SSH key to your {% data variables.product.prodname_dotcom %} account](/authentication/connecting-to-github-with-ssh/adding-a-new-ssh-key-to-your-github-account){% ifversion ssh-commit-verification %}" and "[About commit signature verification](/articles/about-commit-signature-verification){% endif %}."
26+
您可以使用硬件安全密钥来进一步保护 SSH 密钥,当密钥对用于通过 SSH 进行身份验证时,需要将物理硬件安全密钥附加到计算机上。 您还可以通过将密钥添加到 ssh 代理并使用密码来保护您的 SSH 密钥。 有关详细信息,请参阅“[使用 SSH 密钥密码](/authentication/connecting-to-github-with-ssh/working-with-ssh-key-passphrases)”。
2027

21-
You can further secure your SSH key by using a hardware security key, which requires the physical hardware security key to be attached to your computer when the key pair is used to authenticate with SSH. You can also secure your SSH key by adding your key to the ssh-agent and using a passphrase. For more information, see "[Working with SSH key passphrases](/authentication/connecting-to-github-with-ssh/working-with-ssh-key-passphrases)."
28+
{% ifversion fpt or ghec %}若要将 SSH 密钥与使用 SAML 单一登录的组织拥有的存储库一起使用,必须授权该密钥。 有关详细信息,请参阅 {% data variables.product.prodname_ghe_cloud %} 文档中的“[授权 SSH 密钥用于 SAML 单一登录](/enterprise-cloud@latest/authentication/authenticating-with-saml-single-sign-on/authorizing-an-ssh-key-for-use-with-saml-single-sign-on){% ifversion fpt %}”。{% else %}."{% endif %}{% endif %}
2229

23-
{% ifversion fpt or ghec %}To use your SSH key with a repository owned by an organization that uses SAML single sign-on, you must authorize the key. For more information, see "[Authorizing an SSH key for use with SAML single sign-on](/enterprise-cloud@latest/authentication/authenticating-with-saml-single-sign-on/authorizing-an-ssh-key-for-use-with-saml-single-sign-on){% ifversion fpt %}" in the {% data variables.product.prodname_ghe_cloud %} documentation.{% else %}."{% endif %}{% endif %}
30+
为了保持帐户安全,您可以定期检查您的 SSH 密钥列表,并撤销任何无效或已泄漏的密钥。 有关详细信息,请参阅“[查看 SSH 密钥](/github/authenticating-to-github/reviewing-your-ssh-keys)”。
2431

25-
To maintain account security, you can regularly review your SSH keys list and revoke any keys that are invalid or have been compromised. For more information, see "[Reviewing your SSH keys](/github/authenticating-to-github/reviewing-your-ssh-keys)."
26-
27-
{% ifversion fpt or ghec %}
28-
If you haven't used your SSH key for a year, then {% data variables.product.prodname_dotcom %} will automatically delete your inactive SSH key as a security precaution. For more information, see "[Deleted or missing SSH keys](/articles/deleted-or-missing-ssh-keys)."
32+
{% ifversion fpt or ghec %} 如果一年没有使用 SSH 密钥,则作为安全预防措施,{% data variables.product.prodname_dotcom %} 将自动删除你的非活动 SSH 密钥。 有关详细信息,请参阅“[已删除或缺少的 SSH 密钥](/articles/deleted-or-missing-ssh-keys)”。
2933
{% endif %}
3034

31-
{% ifversion fpt %}
32-
Organizations that use {% data variables.product.prodname_ghe_cloud %} can provide SSH certificates, which members can use to access that organization's repositories without adding the certificate to their account on {% data variables.product.product_name %}. If you're using an SSH certificate, you cannot use the certificate to access forks of the organization's repositories, if the fork is owned by your personal account. For more information, see "[About SSH certificate authorities](/enterprise-cloud@latest/organizations/managing-git-access-to-your-organizations-repositories/about-ssh-certificate-authorities)" in the {% data variables.product.prodname_ghe_cloud %} documentation.
33-
{% else ghec or ghes or ghae %}
34-
If you're a member of an organization that provides SSH certificates, you can use your certificate to access that organization's repositories without adding the certificate to your account on {% data variables.product.product_name %}. You cannot use your certificate to access forks of the organization's repositories, if the forks is owned by your personal account. For more information, see "[About SSH certificate authorities](/organizations/managing-git-access-to-your-organizations-repositories/about-ssh-certificate-authorities)."
35+
{% ifversion fpt %} 使用 {% data variables.product.prodname_ghe_cloud %} 的组织可以提供 SSH 证书,成员可以使用该证书访问组织的存储库,而无需将其添加到他们在 {% data variables.product.product_name %} 上的帐户。 如果使用 SSH 证书,当分支为个人帐户所有时,将无法使用该证书访问组织存储库的分支。 有关详细信息,请参阅 {% data variables.product.prodname_ghe_cloud %} 文档中的“[关于 SSH 证书颁发机构](/enterprise-cloud@latest/organizations/managing-git-access-to-your-organizations-repositories/about-ssh-certificate-authorities)”。
36+
{% else ghec or ghes or ghae %} 如果你是提供 SSH 证书的组织成员,可以使用证书来访问组织的存储库,而无需添加证书到你在 {% data variables.product.product_name %} 上的帐户。 当分支为个人帐户所有时,将无法使用该证书访问组织存储库的分支。 有关详细信息,请参阅“[关于 SSH 证书颁发机构](/organizations/managing-git-access-to-your-organizations-repositories/about-ssh-certificate-authorities)”。
3537
{% endif %}
36-
## Further reading
38+
## 延伸阅读
3739

38-
- "[Troubleshooting SSH](/articles/troubleshooting-ssh)"
40+
- [SSH 故障排除](/articles/troubleshooting-ssh)
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
2-
title: Telling Git about your signing key
3-
intro: 'To sign commits locally, you need to inform Git that there''s a GPG{% ifversion ssh-commit-verification %}, SSH,{% endif %} or X.509 key you''d like to use.'
2+
title: 将您的签名密钥告知 Git
3+
intro: '要在本地对提交进行签名,需要向 Git 通知你要使用的 GPG{% ifversion ssh-commit-verification %}SSH{% endif %} X.509 密钥。'
44
redirect_from:
55
- /articles/telling-git-about-your-gpg-key
66
- /articles/telling-git-about-your-signing-key
@@ -15,38 +15,39 @@ topics:
1515
- Identity
1616
- Access management
1717
shortTitle: Tell Git your signing key
18+
ms.openlocfilehash: e78306bb1519f2b7f51ab6bc039bff0b982e48cf
19+
ms.sourcegitcommit: a0ad3bfe2a99c3092e76ca9b3d476cf30988ca55
20+
ms.translationtype: HT
21+
ms.contentlocale: zh-CN
22+
ms.lasthandoff: 10/28/2022
23+
ms.locfileid: '148118993'
1824
---
1925
{% mac %}
2026

21-
## Telling Git about your GPG key
27+
## 将您的 GPG 密钥告知 Git
2228

23-
If you're using a GPG key that matches your committer identity and your verified email address associated with your account on {% ifversion ghae %}{% data variables.product.product_name %}{% else %}{% data variables.location.product_location %}{% endif %}, then you can begin signing commits and signing tags.
29+
如果您使用与您的提交者身份以及 {% ifversion ghae %}{% data variables.product.product_name %}{% else %}{% data variables.location.product_location %}{% endif %} 上帐户关联的已验证电子邮件地址相匹配的 GPG 密钥,则可以开始对提交和标签进行签名。
2430

2531
{% note %}
2632

27-
If you don't have a GPG key that matches your committer identity, you need to associate an email with an existing key. For more information, see "[Associating an email with your GPG key](/articles/associating-an-email-with-your-gpg-key)".
33+
如果您没有与提交者身份匹配的 GPG 密钥,则需要将电子邮件与现有密钥关联。 有关详细信息,请参阅“[将电子邮件与 GPG 密钥关联](/articles/associating-an-email-with-your-gpg-key)”。
2834

2935
{% endnote %}
3036

31-
If you have multiple GPG keys, you need to tell Git which one to use.
37+
如果您有多个 GPG 密钥,则需要告知 Git 要使用哪一个。
3238

33-
{% data reusables.command_line.open_the_multi_os_terminal %}
34-
{% data reusables.gpg.configure-gpg-signing %}
35-
{% data reusables.gpg.list-keys-with-note %}
36-
{% data reusables.gpg.copy-gpg-key-id %}
37-
{% data reusables.gpg.paste-gpg-key-id %}
38-
{% data reusables.gpg.set-auto-sign %}
39-
1. If you aren't using the GPG suite, run the following command in the `zsh` shell to add the GPG key to your `.zshrc` file, if it exists, or your `.zprofile` file:
39+
{% data reusables.command_line.open_the_multi_os_terminal %} {% data reusables.gpg.configure-gpg-signing %} {% data reusables.gpg.list-keys-with-note %} {% data reusables.gpg.copy-gpg-key-id %} {% data reusables.gpg.paste-gpg-key-id %} {% data reusables.gpg.set-auto-sign %}
40+
1. 如果没有使用 GPG 套件,请在 `zsh` shell 中运行以下命令,将 GPG 密钥添加到 `.zshrc` 文件(如果存在)或 `.zprofile` 文件:
4041
```shell
4142
$ if [ -r ~/.zshrc ]; then echo 'export GPG_TTY=$(tty)' >> ~/.zshrc; \
4243
else echo 'export GPG_TTY=$(tty)' >> ~/.zprofile; fi
4344
```
44-
Alternatively, if you use the `bash` shell, run this command:
45+
或者,如果使用 `bash` shell,请运行以下命令:
4546
```shell
4647
$ if [ -r ~/.bash_profile ]; then echo 'export GPG_TTY=$(tty)' >> ~/.bash_profile; \
4748
else echo 'export GPG_TTY=$(tty)' >> ~/.profile; fi
4849
```
49-
1. Optionally, to prompt you to enter a PIN or passphrase when required, install `pinentry-mac`. For example, using [Homebrew](https://brew.sh/):
50+
1. (可选)若要在需要时提示你输入 PIN 或密码,请安装 `pinentry-mac`。 例如,使用 [Homebrew](https://brew.sh/)
5051
```shell
5152
$ brew install pinentry-mac
5253
$ echo "pinentry-program $(which pinentry-mac)" >> ~/.gnupg/gpg-agent.conf
@@ -57,70 +58,56 @@ If you have multiple GPG keys, you need to tell Git which one to use.
5758

5859
{% windows %}
5960

60-
## Telling Git about your GPG key
61+
## 将您的 GPG 密钥告知 Git
6162

62-
If you're using a GPG key that matches your committer identity and your verified email address associated with your account on {% ifversion ghae %}{% data variables.product.product_name %}{% else %}{% data variables.location.product_location %}{% endif %}, then you can begin signing commits and signing tags.
63+
如果您使用与您的提交者身份以及 {% ifversion ghae %}{% data variables.product.product_name %}{% else %}{% data variables.location.product_location %}{% endif %} 上帐户关联的已验证电子邮件地址相匹配的 GPG 密钥,则可以开始对提交和标签进行签名。
6364

6465
{% note %}
6566

66-
If you don't have a GPG key that matches your committer identity, you need to associate an email with an existing key. For more information, see "[Associating an email with your GPG key](/articles/associating-an-email-with-your-gpg-key)".
67+
如果您没有与提交者身份匹配的 GPG 密钥,则需要将电子邮件与现有密钥关联。 有关详细信息,请参阅“[将电子邮件与 GPG 密钥关联](/articles/associating-an-email-with-your-gpg-key)”。
6768

6869
{% endnote %}
6970

70-
If you have multiple GPG keys, you need to tell Git which one to use.
71+
如果您有多个 GPG 密钥,则需要告知 Git 要使用哪一个。
7172

72-
{% data reusables.command_line.open_the_multi_os_terminal %}
73-
{% data reusables.gpg.configure-gpg-signing %}
74-
{% data reusables.gpg.list-keys-with-note %}
75-
{% data reusables.gpg.copy-gpg-key-id %}
76-
{% data reusables.gpg.paste-gpg-key-id %}
77-
{% data reusables.gpg.set-auto-sign %}
73+
{% data reusables.command_line.open_the_multi_os_terminal %} {% data reusables.gpg.configure-gpg-signing %} {% data reusables.gpg.list-keys-with-note %} {% data reusables.gpg.copy-gpg-key-id %} {% data reusables.gpg.paste-gpg-key-id %} {% data reusables.gpg.set-auto-sign %}
7874

7975
{% endwindows %}
8076

8177
{% linux %}
8278

83-
## Telling Git about your GPG key
79+
## 将您的 GPG 密钥告知 Git
8480

85-
If you're using a GPG key that matches your committer identity and your verified email address associated with your account on {% ifversion ghae %}{% data variables.product.product_name %}{% else %}{% data variables.location.product_location %}{% endif %}, then you can begin signing commits and signing tags.
81+
如果您使用与您的提交者身份以及 {% ifversion ghae %}{% data variables.product.product_name %}{% else %}{% data variables.location.product_location %}{% endif %} 上帐户关联的已验证电子邮件地址相匹配的 GPG 密钥,则可以开始对提交和标签进行签名。
8682

8783
{% note %}
8884

89-
If you don't have a GPG key that matches your committer identity, you need to associate an email with an existing key. For more information, see "[Associating an email with your GPG key](/articles/associating-an-email-with-your-gpg-key)".
85+
如果您没有与提交者身份匹配的 GPG 密钥,则需要将电子邮件与现有密钥关联。 有关详细信息,请参阅“[将电子邮件与 GPG 密钥关联](/articles/associating-an-email-with-your-gpg-key)”。
9086

9187
{% endnote %}
9288

93-
If you have multiple GPG keys, you need to tell Git which one to use.
89+
如果您有多个 GPG 密钥,则需要告知 Git 要使用哪一个。
9490

95-
{% data reusables.command_line.open_the_multi_os_terminal %}
96-
{% data reusables.gpg.configure-gpg-signing %}
97-
{% data reusables.gpg.list-keys-with-note %}
98-
{% data reusables.gpg.copy-gpg-key-id %}
99-
{% data reusables.gpg.paste-gpg-key-id %}
100-
{% data reusables.gpg.set-auto-sign %}
101-
1. To add your GPG key to your `.bashrc` startup file, run the following command:
91+
{% data reusables.command_line.open_the_multi_os_terminal %} {% data reusables.gpg.configure-gpg-signing %} {% data reusables.gpg.list-keys-with-note %} {% data reusables.gpg.copy-gpg-key-id %} {% data reusables.gpg.paste-gpg-key-id %} {% data reusables.gpg.set-auto-sign %}
92+
1. 若要将 GPG 密钥添加到 `.bashrc` 启动文件,请运行以下命令:
10293
```bash
10394
$ [ -f ~/.bashrc ] && echo 'export GPG_TTY=$(tty)' >> ~/.bashrc
10495
```
105-
{% endlinux %}
106-
{% ifversion ssh-commit-verification %}
96+
{% endlinux %} {% ifversion ssh-commit-verification %}
10797

108-
## Telling Git about your SSH key
98+
## SSH 密钥告知 Git
10999

110-
You can use an existing SSH key to sign commits and tags, or generate a new one specifically for signing. For more information, see "[Generating a new SSH key and adding it to the ssh-agent](/github/authenticating-to-github/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent)."
100+
可以使用现有 SSH 密钥对提交和标记进行签名,或生成专用于签名的新密钥。 有关详细信息,请参阅“[生成新的 SSH 密钥并将其添加到 ssh-agent](/github/authenticating-to-github/generating-a-new-ssh-key-and-adding-it-to-the-ssh-agent)”。
111101

112102
{% data reusables.gpg.ssh-git-version %}
113103

114-
{% data reusables.command_line.open_the_multi_os_terminal %}
115-
{% data reusables.gpg.configure-ssh-signing %}
116-
{% data reusables.gpg.copy-ssh-public-key %}
117-
{% data reusables.gpg.paste-ssh-public-key %}
104+
{% data reusables.command_line.open_the_multi_os_terminal %} {% data reusables.gpg.configure-ssh-signing %} {% data reusables.gpg.copy-ssh-public-key %} {% data reusables.gpg.paste-ssh-public-key %}
118105

119106
{% endif %}
120107

121108
{% data reusables.gpg.x-509-key %}
122-
## Further reading
109+
## 延伸阅读
123110

124-
- "[Adding a new SSH key to your GitHub account](/authentication/connecting-to-github-with-ssh/adding-a-new-ssh-key-to-your-github-account)."
125-
- "[Signing commits](/articles/signing-commits)"
126-
- "[Signing tags](/articles/signing-tags)"
111+
- [为 GitHub 帐户添加新的 SSH 密钥](/authentication/connecting-to-github-with-ssh/adding-a-new-ssh-key-to-your-github-account)”。
112+
- [对提交签名](/articles/signing-commits)
113+
- [对标记签名](/articles/signing-tags)

0 commit comments

Comments
 (0)