Skip to content
This repository was archived by the owner on Sep 30, 2020. It is now read-only.

Commit 80a7e0b

Browse files
authored
Merge pull request #807 from yfdyh000/zh-CN
Update zh-CN translations
2 parents 92ffd07 + dc7fd88 commit 80a7e0b

21 files changed

+926
-721
lines changed

_layouts/zh-CN/basic.html

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,19 @@
66
<meta http-equiv="X-UA-Compatible" content="IE=edge">
77
<meta name="viewport" content="width=device-width, initial-scale=1">
88
<title>{{ page.title }}</title>
9-
<meta name="keywords" content="Rust, Rust程序语言, rustlang, rust-lang, Mozilla Rust">
9+
<meta name="keywords" content="Rust, Rust 编程语言, rustlang, rust-lang, Mozilla Rust">
1010
<meta name="description" content="一种注重高效、安全、并行的系统程序语言。">
1111

1212
<link rel="stylesheet" href="/css/bootstrap.css">
1313
<link rel="stylesheet" href="/css/style.css">
14+
{% for css_name in page.extra_css %}
15+
<link rel="stylesheet" href="/css/{{ css_name }}">
16+
{% endfor %}
1417
</head>
1518

1619
<body class="container">
1720
<a href="https://github.com/rust-lang/rust">
18-
<img class="ribbon" style="display: none" src="/logos/forkme_zh_cn.svg" alt="从GitHub上拷贝源码" width="298" height="298">
21+
<img class="ribbon" style="display: none" src="/logos/forkme_zh_cn.svg" alt="Fork 在 GitHub 上的代码" width="298" height="298">
1922
</a>
2023

2124
<header>
@@ -37,7 +40,7 @@ <h2><a href="/zh-CN/contribute.html">贡献</a></h2>
3740
{{ content }}
3841

3942
<footer>
40-
<p>本土化页面
43+
<p>其他语言页面
4144
{% include footer.html %}
4245
</p>
4346
</footer>

logos/forkme_zh_cn.svg

Lines changed: 1 addition & 1 deletion
Loading

zh-CN/community.md

Lines changed: 77 additions & 121 deletions
Large diffs are not rendered by default.

zh-CN/conduct.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
---
22
layout: zh-CN/default
3-
title: The Rust Code of Conduct &middot; Rust 程序设计语言
3+
title: Rust 行为守则 &middot; Rust 程序设计语言
44
---
55

6-
# The Rust Code of Conduct
6+
# Rust 行为守则
77

8-
## Conduct
8+
## 行为举止
99

10-
**Contact**: [rust-mods@rust-lang.org](mailto:rust-mods@rust-lang.org)
10+
**联系**[rust-mods@rust-lang.org](mailto:rust-mods@rust-lang.org)
1111

1212
* We are committed to providing a friendly, safe and welcoming environment for all, regardless of level of experience, gender, gender identity and expression, sexual orientation, disability, personal appearance, body size, race, ethnicity, age, religion, nationality, or other similar characteristic.
1313
* On IRC, please avoid using overtly sexual nicknames or other nicknames that might detract from a friendly, safe and welcoming environment for all.
@@ -18,10 +18,10 @@ title: The Rust Code of Conduct &middot; Rust 程序设计语言
1818
* Private harassment is also unacceptable. No matter who you are, if you feel you have been or are being harassed or made uncomfortable by a community member, please contact one of the channel ops or any of the [Rust moderation team](/team.html#Moderation) immediately. Whether you're a regular contributor or a newcomer, we care about making this community a safe place for you and we've got your back.
1919
* Likewise any spamming, trolling, flaming, baiting or other attention-stealing behaviour is not welcome.
2020

21-
## Moderation
21+
## 管理
2222

2323

24-
These are the policies for upholding our community's standards of conduct. If you feel that a thread needs moderation, please contact the [Rust moderation team](/team.html#Moderation).
24+
These are the policies for upholding our community's standards of conduct. 如果你认为某个主题需要被处理,请联系 [Rust 管理团队](/team.html#Moderation)
2525

2626
1. Remarks that violate the Rust standards of conduct, including hateful, hurtful, oppressive, or exclusionary remarks, are not allowed. (Cursing is allowed, but never targeting another user, and never in a hateful manner.)
2727
2. Remarks that moderators find inappropriate, whether listed in the code of conduct or not, are also not allowed.

zh-CN/contribute-bugs.md

Lines changed: 17 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,46 +1,30 @@
11
---
22
layout: zh-CN/default
3-
title: Contributing to Rust &mdash; finding, triaging and fixing issues &middot; Rust 程序设计语言
3+
title: Rust 出力 &mdash; 找出、分类和修复问题 &middot; Rust 程序设计语言
44
---
55

6-
# Contributing to Rust &mdash; finding, triaging and fixing issues
6+
# Rust 出力 &mdash; 找出、分类和修复问题
77

8-
The day-to-day maintenance of the project revolves around Rust's
9-
[issue tracker] and [pull requests][PR], and more help is always
10-
needed. The most basic way to get started contributing to Rust is to
11-
look for the [E-easy] or [E-mentor] labels. These are meant to be
12-
approachable for new Rust programmers.
8+
Rust 项目的的日常维护工作是围绕着[问题跟踪器][issue tracker][拉取请求][PR],并且始终需要更多的贡献。
9+
开始为 Rust 出力的最简单方式是寻找标有 [E-easy][E-mentor] 标签的问题。
10+
它们最适合新手 Rust 程序员。
1311

14-
On `E-mentor` issues an experienced Rust developer has volunteered in
15-
the comments to mentor you through solving the issue and [submitting
16-
the fix via GitHub pull request][pull]. Contact them about the issue,
17-
on the issue tracker by [@mentioning] their name in a comment, on IRC,
18-
or through email. Note that Rust developers get a lot of notifications
19-
and it is easy to miss some; don't hesitate to hunt them down by
20-
whatever means necessary!
12+
在标有 `E-mentor` 的问题上会有一名经验丰富的 Rust 开发人员来自愿帮助你解决该问题和[提交 GitHub 拉取请求][pull]来修复它。
13+
在评论、IRC 中用 [@mentioning] 来联系他们(也可通过电子邮件)。
14+
温馨提醒,Rust 开发人员经常收到大量的通知,所以有时可能错过某些;
15+
不要犹豫!如果你认为他没有注意到你。
2116

22-
Other projects in Rust maintain similar entry-level tasks, including
23-
the web browser [Servo], the HTTP library [hyper], the
24-
source-formatter [rustfmt], the Unix library bindings [nix],
25-
and the lint collection [clippy].
17+
Rust 的其他项目也有其他类似的入门级任务,包括网页浏览器 [Servo],HTTP 库 [hyper],源代码格式化器 [rustfmt],Unix 库绑定 [nix],以及 lint 集 [clippy]
2618

27-
While Rust has an [extensive test suite][test] there is always more to
28-
test. The [E-needstest] label indicates issues that are thought to be
29-
fixed but don't have tests. Writing test cases is a great way to
30-
understand a new project and get started contributing.
19+
虽然 Rust 有一个[广泛的测试套件][test],但测试总是不嫌多的嘛。
20+
[E-needstest] 标签指出了被认为已修复但尚未测试的问题。编写测试用例也是很好的一个了解新项目并开始贡献的方法。
3121

32-
Rust is always in need of people to [triage] issues: reproduce bugs,
33-
minimize test cases, apply labels, close resolved issues. Note that
34-
you'll need elevated GitHub permissions to apply labels, but this is
35-
easy to obtain for somebody with a bit of experience in the
36-
project. Ask a [team member][team].
22+
Rust 始终需要人们来[分流][triage]问题:重现 bug,
23+
最小化的测试用例,应用标签,关闭已解决的问题。
24+
请注意,您需要被提升的 GitHub 权限才能应用标签,
25+
不过卓有经验的人很容易得到它,相关事宜请联系[团队成员][team]
3726

38-
Once you've found your way around the project and have created a few
39-
pull requests in a particular area, consider reviewing others' pull
40-
requests: good reviewership is a rare skill and always appreciated. No
41-
prior permission is needed &mdash; just start constructively and politely
42-
commenting on pull requests that interest you. If you want training
43-
on conducting good code reviews [read this guide][reviews].
27+
在您找到自己的方式为项目出力并创建一些拉取请求后,可以考虑审阅其他人的拉取请求:良好的审阅是一个不可多得的技能。无需事先批准 &mdash; 只需开始礼貌并有建设性地在您感兴趣的拉取请求中评论。如果您想在代码审核的基础上有效分流,[阅读这份指南][reviews]
4428

4529
<!--
4630
TODO: weekly triage email?

zh-CN/contribute-community.md

Lines changed: 8 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,15 @@
11
---
22
layout: zh-CN/default
3-
title: Contributing to Rust &mdash; community building &middot; Rust 程序设计语言
3+
title: Rust 出力 &mdash; 社区建设 &middot; Rust 程序设计语言
44
---
55

6-
# Contributing to Rust &mdash; community building
6+
# Rust 出力 &mdash; 社区建设
77

8-
Help newbies, spread the word, meet interesting people. Make Rust the
9-
shining example of open source development that we all want it to be.
8+
帮助新手、传播它、结识有趣的人。使用 Rust
9+
我们都希望它成为开源开发的一个光辉榜样。
1010

11-
Keep an eye on the [#rust-beginners] channel. This is where we direct
12-
new Rust programmers to ask for help, and it is vital when they do
13-
that they receive prompt, accurate, and courteous responses. Likewise,
14-
[Stack Overflow], [users.rust-lang.org], and [/r/rust], are all forums
15-
where Rust programers commonly look for assistance. If you want
16-
training on answering programmers' questions [read this
17-
guide][helpful].
11+
请您留意 [#rust-beginners] 频道,这是我们为新 Rust 程序员的询问提供帮助的地方,给他们提供迅速、准确和礼貌的回应很重要。与此类似,[Stack Overflow][users.rust-lang.org][/r/rust] 都是 Rust 程序员常来寻求帮助的地方。
12+
如果您想了解怎样更好地回答程序员的提问,[阅读这份指南吧][helpful]
1813

1914
If you are already experienced in some area of the project, please
2015
look out for potential [E-easy] bugs. When you see an
@@ -26,7 +21,7 @@ thus also helpful to triage E-easy bugs for poor descrptions and
2621
improve them.
2722

2823
Experienced developers who are patient and communicate clearly should
29-
consider [mentoring new contributors][mentor]. Tag easy issues with
24+
consider [指导新贡献者][mentor]. Tag easy issues with
3025
[E-mentor] and mention in a comment that you will mentor. Expect people
3126
to contact you about the issue, and attempt to respond promptly.
3227

@@ -56,7 +51,7 @@ Remember as you are advocating Rust though to be considerate of
5651
others' views &mdash; not everybody is going to be receptive to Rust, and
5752
that's just fine.
5853

59-
Meet other Rust community builders in [#rust-community].
54+
[#rust-community] 中能遇到其他 Rust 社区建设者。
6055

6156
<!--
6257
Other ideas:

zh-CN/contribute-compiler.md

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
---
22
layout: zh-CN/default
3-
title: Contributing to Rust &mdash; language, compiler, and the standard library &middot; Rust 程序设计语言
3+
title: Rust 出力 &mdash; 语言、编译器和标准库 &middot; Rust 程序设计语言
44
---
55

6-
# Contributing to Rust &mdash; language, compiler, and the standard library
6+
# Rust 出力 &mdash; 语言、编译器和标准库
77

88

99
The source code to the compiler and standard library are in the main
@@ -33,7 +33,7 @@ incremental compilation. There is yet no single source for information
3333
on work needed here, but ask on [internals.rust-lang.org] or
3434
[#rust-internals] for guidance.
3535

36-
[It's embarrasing when our compiler crashes][ice] &mdash; the
36+
[当我们的编译器崩溃时,这很尴尬][ice] &mdash; the
3737
dreaded 'internal compiler error' (ICE). The [I-ICE] label
3838
tracks these, and they are often plentiful. These are usually
3939
good bugs to start with because it's easy to know when you've fixed
@@ -43,11 +43,10 @@ The performance of Rust code is one of its great advantages; and the
4343
performance of the Rust compiler one of its great weaknesses. Any
4444
improvements to either runtime or &mdash; especially &mdash; compiletime performance
4545
are widely celebrated. The [I-slow] and [A-optimization] labels deal
46-
with runtime performance, and [I-compiletime] with compiletime. We have
47-
a [site that tracks compiletime performance][rustc-perf] on a number
48-
of workloads. The `-Z time-passes` compiler flag can help debug
49-
compiler performance, and Rust code can be profiled with standard
50-
profilers like `perf` on Linux.
46+
with runtime performance, and [I-compiletime] with compiletime.
47+
我们有一个在一些工作流上[跟踪编译性能的网站][rustc-perf]
48+
`-Z time-passes` 编译器标志可以帮助调试编译器性能,
49+
Rust 代码在 Linux 上也能用 `perf` 之类的标准分析器分析。
5150

5251
Major new features go through a [Request for Comments (RFC)][rfc]
5352
process, by which the design is agreed upon. Though it is open to all,
@@ -69,8 +68,7 @@ repository][issue-fcp]. Both FCPs are critical moments to get involved
6968
and express opinions on the direction of the language, and are
7069
advertised in the weekly subteam reports on [internals.rust-lang.org].
7170

72-
Meet other Rust compiler engineers in [#rustc], language
73-
designers in [#rust-lang], and library designers in [#rust-libs].
71+
[#rustc] 中能遇到其他 Rust 编译器工程师,语言设计师在 [#rust-lang],库设计员在 [#rust-libs]
7472

7573
<!--
7674
TODO: guide to compile-time benchmarking

zh-CN/contribute-docs.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
---
22
layout: zh-CN/default
3-
title: Contributing to Rust &mdash; documentation &middot; Rust 程序设计语言
3+
title: Rust 出力 &mdash; 文档 &middot; Rust 程序设计语言
44
---
55

6-
# Contributing to Rust &mdash; documentation
6+
# Rust 出力 &mdash; 文档
77

88
Documentation is never good enough and there's never enough of it.
99
Many aspects of Rust's documentation don't require deep knowledge to
@@ -43,7 +43,7 @@ documentation that is actively developed and in need of contributors
4343
include [Rust By Example], [Rust Design Patterns], and [rust-rosetta].
4444
For other existing documentation projects to contribute to see [rust-learning].
4545

46-
Meet other Rust documentarians in [#rust-docs].
46+
[#rust-docs] 中能遇到其他 Rust 文档编写者。
4747

4848
<!--
4949
TODO: blogging, translation

zh-CN/contribute-libs.md

Lines changed: 14 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,24 +1,20 @@
11
---
22
layout: zh-CN/default
3-
title: Contributing to Rust &mdash; libraries &middot; Rust 程序设计语言
3+
title: Rust 出力 &mdash; &middot; Rust 程序设计语言
44
---
55

6-
# Contributing to Rust &mdash; libraries
6+
# Rust 出力 &mdash;
77

8-
If you want to contribute to Rust by writing volumes of Rust code,
9-
then libraries are where it's at: since Rust is a young language,
10-
there are many types of libraries that either do not exist yet
11-
or are incomplete and in need of improvement or competition.
8+
如果你想通过编写 Rust 代码来为 Rust 出力,
9+
那么库很不错:因为 Rust 是一种年轻的语言,
10+
很多种类的库还尚不存在或并不完整,它们需要改进或竞争者。
1211

13-
Deciding what to write that will have impact and be fun is a common
14-
difficulty. Here are some ideas:
12+
决定写些什么更有乐趣和影响力是一个常见的问题。这里有些想法供你参考:
1513

16-
* Read and participate in the weekly "what's everyone working on
17-
this week" threads on [/r/rust] and [users.rust-lang.org]. These are
18-
packed with exciting announcements from other Rust programmers in
19-
need of collaborators.
20-
* Familiarize yourself with the best Rust libraries through
21-
[awesome-rust] and [libs.rs].
14+
* 阅读和参与 [/r/rust][users.rust-lang.org]
15+
每周的“本周每个人都在做什么”("what's everyone working on
16+
this week")主题。那些包含来自其他需要合作者的 Rust 程序员的激动人心的通知。
17+
* 通过 [awesome-rust][libs.rs] 亲自熟悉最好的 Rust 库。
2218
* Some larger projects, including the web browser [Servo], the HTTP
2319
library [hyper], the source-formatter [rustfmt], the Unix library bindings
2420
[nix], and the lint collection [clippy], tag issues with 'easy' labels for new
@@ -32,14 +28,12 @@ difficulty. Here are some ideas:
3228
* Help guide libraries from [rust-lang-nursery] into rust-lang proper.
3329
Unfortunately there is not much documentation on what needs to be
3430
done here; ask on [#rust-libs].
35-
* Inspect the RFC issue tracker for a [requested community
36-
library][requested] and build it.
37-
* Watch [Github Trending][trending] for currently active Rust projects.
31+
* 查阅 RFC 问题跟踪器中的[社区已请求的库][requested]并建立它。
32+
* 关注 [Github 趋势][trending]了解目前活跃的 Rust 项目。
3833

39-
As a library author you will want to be aware of the [best practices
40-
for Rust libraries][lib-prac].
34+
作为库的设计者,您有必要了解 [Rust 库的最佳实践][lib-prac]
4135

42-
Meet other Rust library designers in [#rust-libs].
36+
[#rust-libs] 中能遇到其他 Rust 库的设计者。
4337

4438
<!--
4539
TODO: Not sure #rust-libs is the place to direct people

zh-CN/contribute-tools.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
---
22
layout: zh-CN/default
3-
title: Contributing to Rust &mdash; tooling, IDEs and infrastructure &middot; Rust 程序设计语言
3+
title: Rust 出力 &mdash; 工具、IDE 及基础设施 &middot; Rust 程序设计语言
44
---
55

6-
# Contributing to Rust &mdash; tooling, IDEs and infrastructure
6+
# Rust 出力 &mdash; 工具、IDE 及基础设施
77

88
Tools play a huge part in the success of a language, and there is a
99
great deal left to implement. ***A major focus of Rust development now

zh-CN/contribute-translations.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
---
2+
layout: default
3+
title: 将 rust-lang.org 译为其他语言以拥抱国际化
4+
---
5+
6+
# Rust is universal
7+
8+
Some docs on contributing translations!

zh-CN/contribute.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ title: 为 Rust 语言做贡献 &middot; Rust 程序设计语言
88
您已经开始学习 Rust 语言。依恋它,想要与它相拥。
99
如果您不确定如何参与到贡献当中,这样页面可以帮助您。
1010

11-
**发现了一个大漏洞 (bug),如何报告?** [漏洞报告指南][bugs]。在此提前致谢!
11+
**发现了一个大漏洞 (bug),如何报告?**[漏洞报告指南][bugs]。在此提前致谢!
1212

1313
Rust 有一个庞大的项目系统,其中最突出的是由 [Rust 开发者][devs]在的GitHub上维护的 [rust-lang 组织][rust-lang]
1414
如果您刚刚开始贡献之旅,您可能对项目的 [CONTRIBUTING.md] 文件感兴趣,
@@ -21,7 +21,7 @@ Rust 有一个庞大的项目系统,其中最突出的是由 [Rust 开发者][
2121
维持一个像 Rust 这样的庞大而活跃的项目基础工作。
2222
* [文档](contribute-docs.html)
2323
不只限于官方文档——库、博客及其他非官方的消息来源。
24-
* [社区建设](contribute-community.html)
24+
* [社区建设](contribute-community.html)
2525
帮助你在 Rust 中的手足同胞,以及壮大 Rust。
2626
* [工具、集成开发环境以及基础设施](contribute-tools.html)
2727
语言的实用与人性化是一门好的语言的关键所在。

zh-CN/documentation.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ title: Rust 语言文档 &middot; Rust 程序设计语言
7979

8080
## 母语文献
8181

82-
如果您需要非英语的本土化资料请[点击这里][locale]
82+
如果您需要非英语的本地化资料,请[点击这里][locale]
8383

8484
中文文献可以快速链接到:
8585
- [简体中文][locale-zh-CN]

0 commit comments

Comments
 (0)