1
0
mirror of https://github.com/google/comprehensive-rust.git synced 2024-12-02 19:06:49 +02:00
Commit Graph

429 Commits

Author SHA1 Message Date
Martin Geisler
413098cdac
Upload build output as artifacts (#342)
This makes it super easy for translators to see the results of their
work: every PR will now have a list of artifacts, one per translation.
2023-02-06 17:20:32 +01:00
Martin Geisler
f9dea3d7a3
Setup redirects after #120 and #177 (#352)
This makes `mdbook` output a simple redirect at the location of the
old pages. I’ll try to add such pages when we shuffle around our
pages to make sure external links stay valid.
2023-02-06 17:10:01 +01:00
Ronald Wotzlaw
13b2c300ce Start of the German translation 2023-02-06 11:56:48 +01:00
Becker A
6361b2ed63
Update welcome-day-1.md (#349)
fix grammar typo
2023-02-06 07:34:55 +00:00
Jiyong Park
9fc203b217
Refine KO translation up to the day 1 part (#302)
Co-authored-by: Evan kim <keispace.kyj@gmail.com>
2023-02-06 12:57:19 +09:00
gendx
2e076cabe7
Reference mdbook installation instructions from running-the-course.md. (#329) 2023-02-03 15:52:06 +00:00
gendx
cc4509f90c
Add historical reference to the Rust 1.0 release. (#335) 2023-02-03 15:51:41 +00:00
gendx
bd98d03b44
Remove dangling links in cargo/rust-ecosystem.md. (#332) 2023-02-03 15:50:15 +00:00
Robin Stringer
06c7346979
Add Brazilian Portuguese translation (#340)
* Add Brazilian Portuguese translation

Adds Brazilian Portuguese translation. Day 1 is respectable and the most glaring machine translation errors are removed throughout. There will of course be exceptions at this early stage.

Conventions: followed standards of the Rust Book translation at https://rust-br.github.io/rust-book-pt-br/
for guidance on Anglicization of programming vocab.
Generally where words refer to a type, method etc in Rust, I switch the translation to English (eg 'Enum', 'read') and stick to the Portuguese when the word refers to an abstract concept (eg shadowing, sombreamento).
The entire 20k lines have been parsed to remove all over-eager translations, many of course of which were in the code blocks ('let mut x / deixe mut x).
Variable / struct names (eg Pessoa -> Person) have been translated so the code runs, comments and some print statements are left in Portuguese.
Assistance welcomed!

* Update pt_BR.po
2023-02-03 15:41:25 +00:00
gendx
ace97aaeb2
Fix typo in basic-syntax/variables.md. (#339) 2023-02-03 15:30:44 +00:00
gendx
b5518e9b16
Add a solution for day 1's bonus question with generics. (#338) 2023-02-03 15:29:49 +00:00
gendx
1936cd5c85
Mention that the syntax is similar to Java as well. (#337) 2023-02-03 15:28:38 +00:00
gendx
22d2bd36e4
Add reference to rustfmt for Debian instructions. (#331) 2023-02-03 15:18:03 +00:00
Andrew Gaul
f33b1f923a
Use f-string in example for consistency (#328)
Also fix typo.
2023-02-03 13:07:29 +00:00
Andrew Walbran
1be641203e
Split out example to separate page. (#319)
The example is quite long and so the page didn't easily fit on the
same screen as the explanation
2023-02-03 10:12:31 +00:00
Andrew Walbran
20f02db5f5
Add a cargo workspace containing both crates (#321)
* Move Cargo.toml for exercises to exercises directory.

* Create a workspace with both exercises and i18n-helpers.

* Build in CI as well as testing.

* Binaries must have a main function.

* No need for workspaces configuration for caching anymore.
2023-02-02 16:14:34 +00:00
Martin Geisler
a07bfa108f
Wrap long line of code (#312)
This line was too big to show during class.
2023-02-01 12:34:10 +01:00
Martin Geisler
476ee283c6
Simplify Vec slide (#313)
The code is probably meant to illustrate the `vec!` macro, but it
feels out of place when teaching: there is already enough material
here to get through.
2023-02-01 10:49:11 +01:00
Martin Geisler
d6182ea498
Fix missing word (#311) 2023-01-31 20:09:00 +00:00
Martin Geisler
c6a54ce9a9
Show the pair returned by duplicate (#314)
This makes it easier to talk about the code as you make changes to the
`duplicate` function.
2023-01-31 21:08:09 +01:00
Martin Geisler
dee5e654c8
Fix order of standard library slides (#310)
The slides now follow the order on the intro slide.
2023-01-31 15:04:17 -05:00
Frieder Bluemle
fd65ff0f0c
Fix JetBrains capitalization (#305)
* Fix JetBrains capitalization

* Revert change to da.po

---------

Co-authored-by: Martin Geisler <martin@geisler.net>
2023-01-31 19:45:54 +00:00
lodisy
330d21ef02 Update traits.md 2023-01-31 11:07:24 +00:00
Igor Petruk
100ee591ed
Update unsafe.md (#252)
* Update unsafe.md

Adding a paragraph explaining that unsafe code is not necessary broken or evil, but it is a mode
where compiler safety features are off.

* Move explanation to speaker notes

To avoid slide being too long. Also edited text slightly.

* Remove extra space

---------

Co-authored-by: Andrew Walbran <qwandor@google.com>
2023-01-30 13:12:51 +00:00
Martin Geisler
efa593e020
Automatically build and test all translations (#298)
This changes the build workflow to first list all available `.po`
files, and then use this information to start parallel jobs which test
each translation.
2023-01-30 13:41:19 +01:00
Martin Geisler
e847c13fb7
Take out unnecessary watch dir (#303)
The directory is already mentioned in our `book.toml`.
2023-01-30 13:33:04 +01:00
Charisee Chiw
601dc8258b
Speaker notes for vec.md (#296)
* Speaker notes for vec.md

* Fix grammar and formatting

* Fix formatting and spelling.

---------

Co-authored-by: Andrew Walbran <qwandor@google.com>
2023-01-30 11:56:30 +00:00
Charisee Chiw
49d24f89cf
Speaker notes for while-let-expressions.md (#294)
* Speaker notes for while-let-expressions.md

#274

* Update while-let-expressions.md

---------

Co-authored-by: Andrew Walbran <qwandor@google.com>
2023-01-30 11:47:56 +00:00
Jiyong Park
1040115d8c
Add Korean translation (#300)
* add ko.po

* translate ko(~23.01.19)

* change speaker-note ko

* change id

* translate ko(~23.01.20)

* ~day3 keynote

* draft done to f3446a91

* add @jiyongp comments of upstream PR #276.

* sync & apply review comments(upstream)

sync 585509bb

* After 10000 line apply review comments(upstream)

* chgange build.yml

* Fix the inconsistent newline character problem for the KO translation

If a msgid does not end with the newline character, so should the
msgstr.

Test: msgfmt --statistics -o /dev/null po/ko.po
No error, but shows `1085 translated messages, 675 untranslated
messages.`

---------

Co-authored-by: Evan kim(cli) <keispace.kyj@gmail.com>
2023-01-30 14:12:33 +09:00
CodeMaster7000
31ae4ac56b
Rename LICENSE.txt to LICENSE (#293)
* Rename LICENSE.txt to LICENSE

* Update credits.md
2023-01-29 14:20:55 +01:00
focksor surooi
43c5344785
Fix typos (#297)
* fix typo in running-the-course.md

* Update modern.md
2023-01-29 11:54:51 +00:00
Mao Yufeng
49e06ffe03
Fix link to solution on Day 3 exercise (#299)
* fix day-3 solutions link

* Fix link description by making it singular

---------

Co-authored-by: Martin Geisler <martin@geisler.net>
2023-01-29 12:52:32 +01:00
Martin Geisler
690039fd53
Filter out “fuzzy” translations (#212)
When the source text is updated, existing translations become
outdated. The `msgmerge` program will attempt to find a similar source
text among the existing translations and will reuse the translation.
The translation is marked “fuzzy” to signal to the translator that it
needs to be proofread.
2023-01-28 14:36:57 +01:00
Andrew Walbran
27b6165202 Implement Error. 2023-01-27 17:54:37 +00:00
Andrew Walbran
caaca140ca Another note for anyhow. 2023-01-27 17:54:37 +00:00
Andrew Walbran
79f5f0dade Add slide about Box<dyn Error> before introducing anyhow. 2023-01-27 17:54:37 +00:00
Andrew Walbran
e5c97e12cb No need for thiserror as well as anyhow. 2023-01-27 17:54:37 +00:00
Andrew Walbran
9fa0e89e90 It makes no sense to use both return and ?. 2023-01-27 17:54:37 +00:00
Andrew Walbran
52d28b155b Mention std::error::Error in speaker notes, and other useful traits. 2023-01-27 17:54:37 +00:00
Andrew Walbran
5dd87192e8 Mention that Send and Sync are unsafe traits. 2023-01-27 17:34:31 +00:00
Andrew Walbran
81cf02ffbe Fix typos and details. 2023-01-27 17:34:31 +00:00
Andrew Walbran
cc402a7788 Add some speaker notes to concurrency chapter. 2023-01-27 17:34:31 +00:00
Martin Geisler
ee36ae318f
Add an aspect-ratio-helper mdbook preprocessor (#187)
The idea is that this will help us make better slides: we can see at a
glance when the slide becomes too full.
2023-01-27 18:30:37 +01:00
Andrew Walbran
c066ab5664 Mention other ABI options. 2023-01-27 17:17:37 +00:00
Andrew Walbran
95c0447e4b Remove comment inside unsafe block.
Martin thinks the safety comment at the top is enough.
2023-01-27 17:17:37 +00:00
Andrew Walbran
facbac4601 Fix typo, and this is not specific to glibc. 2023-01-27 17:17:37 +00:00
Andrew Walbran
6e7916c29b Add a slide about writing unsafe functions. 2023-01-27 17:17:37 +00:00
Andrew Walbran
3cadad4e0a Add slide for unsafe traits. 2023-01-27 17:17:37 +00:00
Andrew Walbran
8c2b3781bb Move extern functions slide under unsafe functions. 2023-01-27 17:17:37 +00:00
Andrew Walbran
7deb5532ea Add speaker notes for extern functions. 2023-01-27 17:17:37 +00:00