diff --git a/locales/core.ftl b/locales/core.ftl new file mode 100644 index 000000000..111ef1370 --- /dev/null +++ b/locales/core.ftl @@ -0,0 +1,31 @@ +-security-at-rust-lang-org-anchor = + security@rust-lang.org +-rust-security-team-key-href = + /static/keys/rust-security-team-key.gpg.ascii +-rust-pgp-key-mit-keyserver-href = + https://pgp.mit.edu/pks/lookup?op=vindex&search=0xEFB9860AE7520DAC" +-wikipedia-rfpolicy-href = + https://en.wikipedia.org/wiki/RFPolicy + +## Security coordinator email addreses and links to their public keys +-security-coordinator-email-anchor = + Steve Klabnik +-security-coordinator-public-key-href = + https://pgp.mit.edu/pks/lookup?op=vindex&search=0xDAE717EFE9424541 +-backup-security-contact-email-anchor = + Alex Crichton +-backup-security-contact-public-key-href = + https://pgp.mit.edu/pks/lookup?op=vindex&search=0x5D54B6F551FF5E33 + +-internals-rust-lang-org-href = + https://internals.rust-lang.org/ + +## Security mailing list links +-rustlang-security-announcements-google-groups-forum-href = + https://groups.google.com/forum/#!forum/rustlang-security-announcements +-rust-security-announcements-mailing-list-href = + https://groups.google.com/group/rustlang-security-announcements/subscribe +-rustlang-security-announcements-subscribe-anchor = + rustlang-security-announcements+subscribe@googlegroups.com +-distros-openwall-email-anchor = + distros@openwall \ No newline at end of file diff --git a/locales/en-US/404.ftl b/locales/en-US/404.ftl new file mode 100644 index 000000000..7c05b74a4 --- /dev/null +++ b/locales/en-US/404.ftl @@ -0,0 +1,7 @@ +### Translation file for the rust-lang.org 404 page. + +## 404 (templates/404.hbs) + +error404-page-title = 404 +error404-subtitle = Whoops, this page doesn’t exist :-( +error404-img-alt = 404 not found image diff --git a/locales/en-US/cli.ftl b/locales/en-US/cli.ftl index c6b6465c8..896049c5e 100644 --- a/locales/en-US/cli.ftl +++ b/locales/en-US/cli.ftl @@ -8,8 +8,6 @@ cli-page-heading = Command-line apps ## templates/components/what/cli/pitch.hbs -cli-pitch-heading = Why Rust? - cli-pitch-solid-img-alt = Shield with a checkmark cli-pitch-solid-heading = Solid and quick cli-pitch-solid-description = Even if you’re just writing a short one-off @@ -73,7 +71,6 @@ cli-maintainable-refactoring-link = Refactoring Rust ## templates/components/what/cli/example.hbs -cli-example-heading = Get started! cli-example-description = Writing a command-line app is a great way to learn Rust. cli-example-inputs-heading = Define your inputs cli-example-main-heading = Write your tool @@ -82,8 +79,6 @@ cli-example-link = Learn more with the CLI book ## templates/components/what/cli/production.hbs -cli-production-heading = Production use - cli-production-sentry-img-alt = sentry logo cli-production-sentry-quote = One of the reasons we liked Rust was the crates.io ecosystem. [...] diff --git a/locales/en-US/code-of-conduct.ftl b/locales/en-US/code-of-conduct.ftl new file mode 100644 index 000000000..32960ef21 --- /dev/null +++ b/locales/en-US/code-of-conduct.ftl @@ -0,0 +1,40 @@ +### Translation file for page: https://www.rust-lang.org/policies/code-of-conduct + +## templates/policies/code-of-conduct.hbs + +coc-page-heading = Code of conduct + +coc-conduct-heading = Conduct +coc-conduct-description = + +coc-conduct-description-team-anchor-text = Rust moderation team +coc-conduct-email-button = Email The Moderation Team + +coc-moderation-heading = Moderation +coc-moderation-description = +

These are the policies for upholding our community’s standards of conduct. If you feel that a thread needs moderation, please contact the { $coc-rust-moderation-team-anchor }.

+
    +
  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.)
  2. +
  3. Remarks that moderators find inappropriate, whether listed in the code of conduct or not, are also not allowed.
  4. +
  5. Moderators will first respond to such remarks with a warning.
  6. +
  7. If the warning is unheeded, the user will be “kicked,” i.e., kicked out of the communication channel to cool off.
  8. +
  9. If the user comes back and continues to make trouble, they will be banned, i.e., indefinitely excluded.
  10. +
  11. Moderators may choose at their discretion to un-ban the user if it was a first offense and they offer the offended party a genuine apology.
  12. +
  13. If a moderator bans someone and you think it was unjustified, please take it up with that moderator, or with a different moderator, in private. Complaints about bans in-channel are not allowed.
  14. +
  15. Moderators are held to a higher standard than other community members. If a moderator creates an inappropriate situation, they should expect less leeway than others.
  16. +
+

In the Rust community we strive to go the extra step to look out for each other. Don’t just aim to be technically unimpeachable, try to be your best self. In particular, avoid flirting with offensive or sensitive issues, particularly if they’re off-topic; this all too often leads to unnecessary fights, hurt feelings, and damaged trust; worse, it can drive people away from the community entirely.

+

And if someone takes issue with something you said or did, resist the urge to be defensive. Just stop doing what it was they complained about and apologize. Even if you feel you were misinterpreted or unfairly accused, chances are good there was something you could’ve communicated better — remember that it’s your responsibility to make your fellow Rustaceans comfortable. Everyone wants to get along and we are all here first and foremost because we want to talk about cool technology. You will find that people will be eager to assume good intent and forgive as long as you earn their trust.

+

The enforcement policies listed above apply to all official Rust venues; including Discord channels (https://discord.gg/rust-lang); GitHub repositories under rust-lang, rust-lang-nursery, and rust-lang-deprecated; and all forums under rust-lang.org (users.rust-lang.org, internals.rust-lang.org). For other projects adopting the Rust Code of Conduct, please contact the maintainers of those projects for enforcement. If you wish to use this code of conduct for your own project, consider explicitly mentioning your moderation policy or making a copy with your own moderation policy so as to avoid confusion.

+

Adapted from the Node.js Policy on Trolling as well as the Contributor Covenant v1.3.0.

+ +coc-moderation-description-team-anchor-text = Rust moderation team \ No newline at end of file diff --git a/locales/en-US/common.ftl b/locales/en-US/common.ftl index 6c5f657ae..9e868da29 100644 --- a/locales/en-US/common.ftl +++ b/locales/en-US/common.ftl @@ -1,6 +1,13 @@ -# Translations that appear on most/all pages +## Translations that appear on many pages -# components/nav.hbs +rust = Rust + +get-started-exclamation = Get started! +getting-started = Getting started +why-rust = Why Rust? +production-use = Production use + +## components/nav.hbs nav-install = Install nav-learn = Learn @@ -13,7 +20,8 @@ choose-language = Language nav-logo-alt = Rust Logo -# components/footer.hbs +## components/footer.hbs + footer-doc = Documentation footer-ask = Ask a Question on the Users Forum footer-status = Check Website Status diff --git a/locales/en-US/core.ftl b/locales/en-US/core.ftl deleted file mode 100644 index 4ece4aafe..000000000 --- a/locales/en-US/core.ftl +++ /dev/null @@ -1,2 +0,0 @@ -rust = Rust -rust-language-server = Rust Language Server diff --git a/locales/en-US/embedded.ftl b/locales/en-US/embedded.ftl new file mode 100644 index 000000000..fd2a83d73 --- /dev/null +++ b/locales/en-US/embedded.ftl @@ -0,0 +1,104 @@ +### Translation file for https://www.rust-lang.org/what/embedded + +## templates/what/embedded.hbs + +# Page Title +embedded-page-title = Embedded devices + + +## Why Rust? (templates/components/what/pitch.hbs) + +embedded-pitch-analysis-alt = A microscope +embedded-pitch-analysis-heading = Powerful static analysis +embedded-pitch-analysis-description = + Enforce pin and peripheral configuration at compile time. Guarantee that resources won’t be used by unintended parts of your application. + +embedded-pitch-memory-alt = A RAM stick +embedded-pitch-memory-heading = Flexible memory +embedded-pitch-memory-description = + Dynamic memory allocation is optional. Use a global allocator and dynamic data structures. Or leave out the heap altogether and statically allocate everything. + +embedded-pitch-concurrency-alt = Gears +embedded-pitch-concurrency-heading = Fearless concurrency +embedded-pitch-concurrency-description = + Rust makes it impossible to accidentally share state between threads. Use any concurrency approach you like, and you’ll still get Rust’s strong guarantees. + +embedded-pitch-interop-alt = Handshake +embedded-pitch-interop-heading = Interoperability +embedded-pitch-interop-description = + Integrate Rust into your existing C codebase or leverage an existing SDK to write a Rust application. + +embedded-pitch-portability-alt = Luggage trolley +embedded-pitch-portability-heading = Portability +embedded-pitch-portability-description = + Write a library or driver once, and use it with a variety of systems, ranging from very small microcontrollers to powerful SBCs. + +embedded-pitch-community-alt = Shield Logo +embedded-pitch-community-heading = Community driven +embedded-pitch-community-description = + As part of the Rust open source project, support for embedded systems is driven by a best-in-class open source community, with support from commercial partners. + +embedded-learn-more-link = Learn more + + +## Showcase (templates/components/what/showcase.hbs) + +embedded-showcase-heading = Showcase + +embedded-showcase-quote = + “I was so excited when I came across Rust, from Mozilla. Rust is a new programming language, with the tag line ‘safe, fast, concurrent – pick three.’ It also has an assured future, with a powerful, committed user community.” +embedded-showcase-quote-attribution = + – Jonathan Pallant, Senior Consultant, Cambridge Consultants +embedded-showcase-see-more-link = See More + +embedded-showcase-video-description = + Securing the future, with Rust from Cambridge Consultants on Vimeo. + + +## Get started! (templates/components/what/embedded/get-started.hbs) + +embedded-get-started-discovery-book-alt = DIP-6 package +embedded-get-started-discovery-book-heading = The Discovery book +embedded-get-started-discovery-book-description = + Learn embedded development from the ground up—using Rust! + +embedded-get-started-embedded-rust-book-alt = TFQP-16 package +embedded-get-started-embedded-rust-book-heading = The Embedded Rust book +embedded-get-started-embedded-rust-book-description = + Already familiar with Embedded development? Jump in with Rust and start reaping the benefits. + +embedded-get-started-embedonomicon-alt = BGA package +embedded-get-started-embedonomicon-heading = The Embedonomicon +embedded-get-started-embedonomicon-description = + Look under the hood of foundational embedded libraries. + +embedded-get-started-read-link = Read +embedded-get-started-more-documentation-link = More Documentation + + +## Production use (templates/components/what/embedded/testimonials.hbs) + +embedded-testimonials-sensirion-alt = Sensirion logo +embedded-testimonials-sensirion-quote = + At Sensirion we recently used Rust to create an embedded demonstrator for Sensirion’s Particulate Matter Sensor. Due to the easy cross-compilation and the availability of many high quality crates on crates.io we quickly ended up with a fast and robust demonstrator. +embedded-testimonials-sensirion-attribution = + – Raphael Nestler, Software Engineer, Sensirion + +embedded-testimonials-airborne-alt = Airborne Engineering Ltd logo +embedded-testimonials-airborne-quote = + At Airborne Engineering Ltd. we recently used Rust to write an Ethernet bootloader, blethrs, for our in-house data acquisition system. Rust is a promising language and we’re excited to use it for our future projects, embedded and otherwise. +embedded-testimonials-airborne-attribution = + – Dr. Adam Greig, Instrumentation Engineer, Airborne Engineering Ltd. + +embedded-testimonials-49nord-alt = 49nord logo +# "Fluent" requires a square bracket which is the first character of a line to be escaped like this: {"["} See https://projectfluent.org/fluent/guide/special.html +embedded-testimonials-49nord-quote = + {"["}Rust] enables us to ship software faster and more correct than we thought possible. Thanks to Rust, we can take memory safety for granted, while other benefits of a zero-overhead language with a sophisticated type system help us develop maintainable software. Rust makes our customers happy, as well as our engineers. +embedded-testimonials-49nord-attribution = + – Marc Brinkmann, CEO, 49nord + +embedded-testimonials-terminal-tech-alt = Terminal Technologies logo +embedded-testimonials-terminal-tech-quote = + We think it’s really cool that we can use a modern nice language in the embedded space where usually there’s no alternative to C/C++ +embedded-testimonials-terminal-tech-attribution = + – Aleksei Arbuzov, Senior Software Engineer, Terminal Technologies diff --git a/locales/en-US/homepage.ftl b/locales/en-US/homepage.ftl index 0dccc9529..86cb2b255 100644 --- a/locales/en-US/homepage.ftl +++ b/locales/en-US/homepage.ftl @@ -28,7 +28,6 @@ production-testimonial-yelp-alt = Yelp Logo # components/panels/language-values.hbs -language-values-why-rust = Why Rust? language-values-performance = Performance language-values-performance-blurb = Rust is blazingly fast and memory-efficient: with no runtime or diff --git a/locales/en-US/learn.ftl b/locales/en-US/learn.ftl index bf78d8cc2..ae8aa8773 100644 --- a/locales/en-US/learn.ftl +++ b/locales/en-US/learn.ftl @@ -64,7 +64,6 @@ learn-unstable-button = Read the unstable book ## learn/get-started.hbs -learn-setup-heading = Getting started learn-setup = Quickly set up a Rust development environment and write a small app! learn-install-heading = Installing Rust diff --git a/locales/en-US/licenses.ftl b/locales/en-US/licenses.ftl new file mode 100644 index 000000000..9a3f65535 --- /dev/null +++ b/locales/en-US/licenses.ftl @@ -0,0 +1,20 @@ +### Translation file for page: https://www.rust-lang.org/policies/licenses + +## templates/policies/licenses.hbs + +licenses-page-heading = Licenses + +licenses-license-heading = License +licenses-license-general-description = + The Rust Programming Language and all other official projects, including this website, are generally dual-licensed: +licenses-apache-v-2-0-link = Apache License, Version 2.0 +licenses-mit-link = MIT license +licenses-license-specific-description = +

Specific licensing info for each project can be found in its GitHub Repository.

+

Third-party logos may be subject to third-party copyrights and trademarks, and are not available under the same license as the rest of the Rust website.

+

If you have a specific question or concern about how the Rust project or any of its associated projects are licensed, please contact the Rust Core Team.

+licenses-license-email-link = Email The Core Team + +licenses-attribution-heading = Attribution +licenses-attribution-description = + Icons made by Freepik from www.flaticon.com, licensed by CC-3.0-BY diff --git a/locales/en-US/media-guide.ftl b/locales/en-US/media-guide.ftl new file mode 100644 index 000000000..35a67f3f0 --- /dev/null +++ b/locales/en-US/media-guide.ftl @@ -0,0 +1,80 @@ +### Translation file for page: https://www.rust-lang.org/policies/media-guide +### templates/policies/media-guide.hbs + +## Page title +media-guide-page-heading = Media guide + +## Art license +media-guide-art-license-heading = Art license +media-guide-art-license-description = +

The Rust and Cargo logos (bitmap and vector) are owned by Mozilla and distributed under the terms of the Creative Commons Attribution license (CC-BY). This is the most permissive Creative Commons license, and allows reuse and modifications for any purpose. The restrictions are that distributors must “give appropriate credit, provide a link to the license, and indicate if changes were made.” Note that use of these logos, and the Rust and Cargo names, is also governed by trademark; our trademark policy is described below.

+ +## Trademark policy +media-guide-trademark-policy-heading = Trademark policy +media-guide-trademark-policy-description = +

The Rust and Cargo names and brands make it possible to say what is officially part of the Rust community, and what isn’t. So we’re careful about where we allow them to appear. But at the same time, we want to allow for as much creative use of these brands as we can. The policy laid out here explains how we strike a balance. If you want to use these names or brands, especially in a commercial way, please read this page or feel free to reach out and ask us about it!

+

TL;DR: Most non-commercial uses of the Rust/Cargo names and logos are allowed and do not require permission; most commercial uses require permission. In either case, the most important rule is that uses of the trademarks cannot appear official or imply any endorsement by the Rust project.

+

If you have any doubts about whether your intended use of a Rust Trademark requires permission, please contact us at trademark@rust-lang.org.

+

This document was derived in part from the Python Software Foundation Trademark Usage Policy. This document is not an official statement of Mozilla trademark policy, but serves to clarify Mozilla’s trademark policy as it relates to Rust.

+ +## The Rust trademarks +media-guide-rust-trademarks-heading = The Rust trademarks +media-guide-rust-trademarks-description = +

The Rust programming language is an open source, community project governed by a core team. It is also sponsored by the Mozilla Foundation (“Mozilla”), which owns and protects the Rust and Cargo trademarks and logos (the “Rust Trademarks”). This document provides information about use of the Rust Trademarks specific to a programming language, as well as examples of common ways people might want to use these trademarks, with explanations as to whether those uses are OK or not or require permission. This document supplements the official Mozilla trademark policy which governs use of all Mozilla trademarks.

+

The Rust Trademarks include two word marks and two logos:

+ +

Trademarks are names and designs that tell the world the source of a good or service. Protecting trademarks for an open source project is particularly important. Anyone can change the source code and produce a product from that code, so it’s important that only the original product, or variations that have been approved by the project, use the project’s trademarks. By limiting use of the Rust Trademarks, Mozilla and the Rust project can help users and developers know they’re getting the product produced by the Rust project and not someone else’s modified version. The trademark assures users and developers of the quality and safety of the product they’re using.

+media-guide-rust-trademarks-rust-img-alt = rust logo +media-guide-rust-trademarks-cargo-img-alt = cargo logo + + +## Using the trademarks +media-guide-tm-use-heading = Using the trademarks + +media-guide-tm-use-appearance-heading = Appearing official, affiliated, or endorsed +media-guide-tm-use-appearance-description = +

The most basic rule is that the Rust trademarks cannot be used in ways that appear (to a casual observer) official, affiliated, or endorsed by the Rust project or Mozilla, unless you have written permission from the Rust core team. This is the fundamental way we protect users and developers from confusion.

+

Since this rule is about managing perception, it is subjective and somewhat difficult to nail down concretely. There are some obvious ways to avoid problems, like including the word “unofficial” in a very prominent way, but if you have any doubts, we would be more than happy to help; just send an e-mail to trademark@rust-lang.org.

+ +media-guide-tm-use-basics-heading = The basics: referring to Rust/Cargo +media-guide-tm-use-basics-description = +

As with any trademark, the Rust and Cargo word marks can be used with minimal restriction to refer to the Rust programming language and the Cargo package manager and registry.

+

They may not be used:

+ + +media-guide-tm-use-implicit-approval-heading = Uses that do not require explicit approval +media-guide-tm-use-implicit-approval-description = +

There are a variety of uses that do not require explicit approval. However, in all of the cases outlined below, you must ensure that use of the Rust trademarks does not appear official, as explained above.

+ + +media-guide-tm-use-explicit-approval-heading = Uses that require explicit approval +media-guide-tm-use-explicit-approval-description = + + +## Helping out +media-guide-helping-out-heading = Helping out +media-guide-helping-out-description = +

As a member of the Rust community, please keep an eye out for questionable uses of the Rust logo and “Rust” word mark. You can report potential misuse to trademark@rust-lang.org. We will evaluate each case and take appropriate action.

+

Please do not approach users of the trademarks with a complaint. That should be left to Mozilla and its representatives. Thanks!

+

If you have a specific question or concern about promoting Rust or using its trademarks, please contact the Rust Core Team.

+media-guide-helping-out-link = Email The Core Team diff --git a/locales/en-US/networking.ftl b/locales/en-US/networking.ftl new file mode 100644 index 000000000..97593a1ce --- /dev/null +++ b/locales/en-US/networking.ftl @@ -0,0 +1,68 @@ +## templates/what/networking.hbs + +networking-header = Networking + +## templates/components/what/networking/get-started.hbs + +networking-get-started = Rust has a growing ecosystem of easy-to-use libraries for the web. Here are just two examples: +networking-get-started-post-json = POST some JSON +networking-get-started-take-json = Handle a JSON POST +networking-get-started-reqwest = Learn more about reqwest +networking-get-started-rocket = Learn more about Rocket + +## templates/components/what/networking/pitch.hbs + +networking-pitch-footprint-header = Low footprint +networking-pitch-footprint = + Take control over resource usage to keep memory and CPU footprint to a minimum. + Get help from the compiler to make sure you’ve got it right. + And do this with an ecosystem that is productive and pleasant to use. +networking-pitch-footprint-alt = A feather + + +networking-pitch-secure-header = Secure and reliable +networking-pitch-secure = + Rust’s powerful type checker prevents whole classes of bugs. + Make sure you know exactly when and where state is shared and mutated. + Get help catching points of failure — before deployment. +networking-pitch-secure-alt = A shield + + +networking-pitch-concurrent-header = Concurrent at scale +networking-pitch-concurrent = + Use any mixture of concurrency approaches that works for you. + Rust will make sure you don’t accidentally share state between threads or tasks. + It empowers you to squeeze every last bit of scaling, fearlessly. +networking-pitch-concurrent-alt = Connected gears + + +## templates/components/what/networking/production.hbs + +networking-production-testimonial-mozilla = + Migrating our Push connection infrastructure to Rust has provided us with an easier to maintain + code-base with a focus on correctness while delivering fantastic performance. We are now + handling up to 20 million websocket connections at once during peak hours with Rust servers. +networking-production-testimonial-mozilla-attribution = Benjamin Bangert, Staff Engineer, Mozilla + +networking-production-testimonial-buoyant = + Rust is foundational to the Linkerd project’s technology roadmap. Its type system allows us to + build modular, testable, composable units without sacrificing runtime performance. What’s been + most surprising, though, is how Rust’s lifetime/borrow checking system allows us to avoid large + classes of resource leaks. After 2 years, I really can’t imagine using any other language for + the job. +networking-production-testimonial-buoyant-attribution = Oliver Gould, CTO, Buoyant + +networking-production-testimonial-1aim = + Rust's powerful type system enables safe refactoring and catches many classes of bugs at + compile time. Its low footprint and high performance, complemented by guaranteed memory safety + and rock-solid error handling make it perfect for writing security critical and complex + business logic for our backend. The ultra-high stability means that our Rust applications are + the last part of our stack we ever have to worry about. We have been running a almost 100% Rust + backend in production since end of 2015 and it has never failed us so far! + +networking-production-testimonial-1aim-attribution = Yann Leretaille, 1aim + + + + + diff --git a/locales/en-US/policies.ftl b/locales/en-US/policies.ftl new file mode 100644 index 000000000..50669c992 --- /dev/null +++ b/locales/en-US/policies.ftl @@ -0,0 +1,15 @@ +### Translation file for page: https://www.rust-lang.org/policies/ + +## templates/policies/index.hbs + +policies-page-heading = Policies + +policies-page-description = This page links to the comprehensive set of Rust’s policies. + +policies-code-of-conduct-link = Code of Conduct +policies-licenses-link = Licenses +policies-media-guide-link = Logo Policy and Media Guide +policies-security-link = Security Disclosures + +policies-reach-out-description = Didn’t find what you were looking for? Have a question? Please reach out! +policies-reach-out-link = Message the Core Team diff --git a/locales/en-US/security.ftl b/locales/en-US/security.ftl new file mode 100644 index 000000000..fceafe7d2 --- /dev/null +++ b/locales/en-US/security.ftl @@ -0,0 +1,38 @@ +### Translation file for page: https://www.rust-lang.org/policies/security +### templates/policies/security.hbs + +security-page-heading = Security policy + +security-reporting-heading = Reporting +security-reporting-link = email security@rust-lang.org +# Anchor text for +security-reporting-description = +

Safety is one of the core principles of Rust, and to that end, we would like to ensure that Rust has a secure implementation. Thank you for taking the time to responsibly disclose any issues you find.

+

All security bugs in the Rust distribution should be reported by email to { -security-at-rust-lang-org-anchor }. This list is delivered to a small security team. Your email will be acknowledged within 24 hours, and you’ll receive a more detailed response to your email within 48 hours indicating the next steps in handling your report. If you would like, you can encrypt your report using our public key. This key is also On MIT’s keyserver and reproduced below.

+

This email address receives a large amount of spam, so be sure to use a descriptive subject line to avoid having your report be missed. After the initial reply to your report, the security team will endeavor to keep you informed of the progress being made towards a fix and full announcement. As recommended by RFPolicy, these updates will be sent at least every five days. In reality, this is more likely to be every 24-48 hours.

+

If you have not received a reply to your email within 48 hours, or have not heard from the security team for the past five days, there are a few steps you can take (in order):

+ +

Please note that the discussion forums are public areas. When escalating in these venues, please do not discuss your issue. Simply say that you’re trying to get a hold of someone from the security team.

+ +security-disclosure-heading = Disclosure policy +security-disclosure-description = +

The Rust project has a 5 step disclosure process.

+
    +
  1. The security report is received and is assigned a primary handler. This person will coordinate the fix and release process.
  2. +
  3. The problem is confirmed and a list of all affected versions is determined.
  4. +
  5. Code is audited to find any potential similar problems.
  6. +
  7. Fixes are prepared for all releases which are still under maintenance. These fixes are not committed to the public repository but rather held locally pending the announcement.
  8. +
  9. On the embargo date, the Rust security mailing list is sent a copy of the announcement. The changes are pushed to the public repository and new builds are deployed to rust-lang.org. Within 6 hours of the mailing list being notified, a copy of the advisory will be published on the Rust blog.
  10. +
+

This process can take some time, especially when coordination is required with maintainers of other projects. Every effort will be made to handle the bug in as timely a manner as possible, however it’s important that we follow the release process above to ensure that the disclosure is handled in a consistent manner.

+ +security-receiving-heading = Receiving security updates +security-receiving-description = +

The best way to receive all the security announcements is to subscribe to the Rust security announcements mailing list (alternatively by sending an email to { -rustlang-security-announcements-subscribe-anchor }). The mailing list is very low traffic, and it receives the public notifications the moment the embargo is lifted.

+

We will announce vulnerabilities 72 hours before the embargo is lifted to { -distros-openwall-email-anchor }, so that Linux distributions can update their packages.

+ +security-pgp-key-heading = Plaintext PGP key diff --git a/locales/en-US/tools.ftl b/locales/en-US/tools.ftl index 9e5383eb9..de6437638 100644 --- a/locales/en-US/tools.ftl +++ b/locales/en-US/tools.ftl @@ -3,8 +3,7 @@ tools-editor-support-heading = First-class editor support tools-editor-support-description = Whether you prefer working with code from the command line, or using rich graphical editors, there’s a Rust integration available for your editor of choice. Or you can build your - own using the - { $rls-link } + own using the Rust Language Server,/a> tools-build-heading = Bring calmness to your builds tools-build-description = Cargo is the build tool for Rust. It bundles all @@ -59,7 +58,6 @@ install-using-rustup-heading = Using rustup (Recommended) install-notes-heading = Notes about Rust installation -install-notes-getting-started-heading = Getting started install-notes-getting-started-description = If you're just getting started with Rust and would like a more detailed walk-through, see our getting started page. diff --git a/locales/en-US/wasm.ftl b/locales/en-US/wasm.ftl new file mode 100644 index 000000000..e3eccd007 --- /dev/null +++ b/locales/en-US/wasm.ftl @@ -0,0 +1,81 @@ +### Translation file for https://www.rust-lang.org/what/wasm + +## Web-Assembly (templates/what/wasm.hbs) + +wasm-page-title = Web­Assembly + + +## Why Rust? (templates/components/what/wasm/pitch.hbs) + +wasm-why-rust-predictable-alt = Gears +wasm-why-rust-predictable-heading = Predictable performance +wasm-why-rust-predictable-description = + No unpredictable garbage collection pauses. No JIT compiler performance cliffs. Just low-level control coupled with high-level ergonomics. + +wasm-why-rust-small-code-alt = A microscope +wasm-why-rust-small-code-heading = Small code size +wasm-why-rust-small-code-description = + Small code size means faster page loads. Rust-generated .wasm doesn’t include extra bloat, like a garbage collector. Advanced optimizations and tree shaking remove dead code. + +wasm-why-rust-amenities-alt = Luggage +wasm-why-rust-amenities-heading = Modern amenities +wasm-why-rust-amenities-description = + A lively ecosystem of libraries to help you hit the ground running. Expressive, zero-cost abstractions. And a welcoming community to help you learn. + + +## Get started! (templates/components/what/wasm/get-started.hbs) + +wasm-get-started-wasm-alt = WebAssembly Logo +wasm-get-started-wasm-description = + Learn more about the fast, safe, and open virtual machine called WebAssembly, and read its standard. +wasm-get-started-wasm-link = Learn More + +wasm-get-started-book-alt = wasm ferris +wasm-get-started-book-description = + Learn how to build, debug, profile, and deploy WebAssembly applications using Rust! +wasm-get-started-book-link = Read The Book + +wasm-get-started-mdn-alt = MDN logo +wasm-get-started-mdn-description = + Learn more about WebAssembly on the Mozilla Developer Network. +wasm-get-started-mdn-link = Check it out + + +## Plays well with JavaScript (templates/components/what/wasm/js.hbs) + +wasm-js-heading = Plays well with JavaScript + +wasm-js-augment-heading = Augment, don’t replace +wasm-js-augment-description = + The dream of WebAssembly is not to kill JavaScript but to work alongside of it, to help super charge processing-heavy or low-level tasks — tasks that benefit from Rust’s focus on performance. + +wasm-js-toolchains-heading = Works with familiar toolchains +wasm-js-toolchains-description = + Publish Rust WebAssembly packages to package registries like npm. Bundle and ship them with webpack, Parcel, and others. Maintain them with tools like npm audit and Greenkeeper. + +wasm-js-interop-heading = Seamless interop +wasm-js-interop-description = + Automatically generate binding code between Rust, WebAssembly, and JavaScript APIs. Take advantage of libraries like web-sys that provide pre-packaged bindings for the entire web platform. + + +## Production use (templates/components/what/wasm/production.hbs) + +wasm-production-cloudflare-alt = cloudflare logo +wasm-production-cloudflare-quote = + We can compile Rust to WASM, and call it from Serverless functions woven into the very fabric of the Internet. That’s huge and I can’t wait to do more of it. +wasm-production-cloudflare-attribution = + Steven Pack, Serverless Rust with Cloudflare Workers + +wasm-production-mozilla-alt = firefox +# If an opening square bracket is the first character on a line, it must be escaped like this: {"["}. See https://projectfluent.org/fluent/guide/special.html +wasm-production-mozilla-quote = + The JavaScript implementation [of the source-map library] has accumulated convoluted code in the name of performance, and we replaced it with idiomatic Rust. Rust does not force us to choose between clearly expressing intent and runtime performance. +wasm-production-mozilla-attribution = + Nick Fitzgerald, Oxidizing Source Maps with Rust and WebAssembly + +wasm-production-dropbox-alt = dropbox +# If an opening square bracket is the first character on a line, it must be escaped like this: {"["}. See https://projectfluent.org/fluent/guide/special.html +wasm-production-dropbox-quote = + {"["}Rust’s] properties make it easy to embed the DivANS codec in a webpage with WASM, as shown above. +wasm-production-dropbox-attribution = + Daniel Reiter Horn and Jongmin Baek, Building Better Compression Together with DivANS diff --git a/locales/xx-AU/common.ftl b/locales/xx-AU/common.ftl index fb1840cd0..4d24c0e84 100644 --- a/locales/xx-AU/common.ftl +++ b/locales/xx-AU/common.ftl @@ -1,5 +1,7 @@ # Translations that appear on most/all pages +rust = ʇsnɹ + # components/nav.hbs nav-install = llɐʇsuI nav-learn = uɹɐǝ˥ diff --git a/locales/xx-AU/core.ftl b/locales/xx-AU/core.ftl deleted file mode 100644 index a056f9487..000000000 --- a/locales/xx-AU/core.ftl +++ /dev/null @@ -1,2 +0,0 @@ -rust = ʇsnɹ -rust-language-server = ɹǝʌɹǝS ǝƃɐnƃuɐ˥ ʇsnɹ diff --git a/locales/xx-AU/tools.ftl b/locales/xx-AU/tools.ftl index 058dc82bd..89b169ffb 100644 --- a/locales/xx-AU/tools.ftl +++ b/locales/xx-AU/tools.ftl @@ -1,4 +1,4 @@ -tools-editor-support-description = { $rls-link } ǝɥʇ ƃuᴉsn uʍo ɹnoʎ plᴉnq uɐɔ +tools-editor-support-description = ɹǝʌɹǝS ǝƃɐnƃuɐ˥ ʇsnɹ ǝɥʇ ƃuᴉsn uʍo ɹnoʎ plᴉnq uɐɔ noʎ ɹO ˙ǝɔᴉoɥɔ ɟo ɹoʇᴉpǝ ɹnoʎ ɹoɟ ǝlqɐlᴉɐʌɐ uoᴉʇɐɹƃǝʇuᴉ ʇsnɹ ɐ s’ǝɹǝɥʇ 'sɹoʇᴉpǝ lɐɔᴉɥdɐɹƃ ɥɔᴉɹ ƃuᴉsn ɹo 'ǝuᴉl puɐɯɯoɔ ǝɥʇ ɯoɹɟ ǝpoɔ ɥʇᴉʍ ƃuᴉʞɹoʍ ɹǝɟǝɹd noʎ ɹǝɥʇǝɥM diff --git a/src/i18n.rs b/src/i18n.rs index b0b816989..02995f07c 100644 --- a/src/i18n.rs +++ b/src/i18n.rs @@ -17,6 +17,8 @@ use std::path::Path; use fluent_bundle::{FluentBundle, FluentResource, FluentValue}; lazy_static! { + static ref CORE_RESOURCE: FluentResource = + read_from_file("./locales/core.ftl").expect("cannot find core.ftl"); static ref RESOURCES: HashMap> = build_resources(); static ref BUNDLES: HashMap> = build_bundles(); } @@ -296,7 +298,9 @@ pub fn read_from_dir>(dirname: P) -> io::Result) -> FluentBundle<'static> { let mut bundle = FluentBundle::new(&[lang]); - + bundle + .add_resource(&CORE_RESOURCE) + .expect("Failed to add core resource to bundle"); for res in resources { bundle .add_resource(res) @@ -311,9 +315,11 @@ fn build_resources() -> HashMap> { let entries = read_dir("./locales").unwrap(); for entry in entries { let entry = entry.unwrap(); - if let Ok(lang) = entry.file_name().into_string() { - let resources = read_from_dir(entry.path()).unwrap(); - all_resources.insert(lang, resources); + if entry.file_type().unwrap().is_dir() { + if let Ok(lang) = entry.file_name().into_string() { + let resources = read_from_dir(entry.path()).unwrap(); + all_resources.insert(lang, resources); + } } } all_resources diff --git a/src/main.rs b/src/main.rs index 4bf5b5343..5fce72819 100644 --- a/src/main.rs +++ b/src/main.rs @@ -42,7 +42,8 @@ use std::path::{Path, PathBuf}; use rand::seq::SliceRandom; use rocket::{ - http::Status, + http::{RawStr, Status}, + request::{FromParam, Request}, response::{NamedFile, Redirect}, }; use rocket_contrib::templates::Template; @@ -89,7 +90,12 @@ fn get_title(page_name: &str) -> String { #[get("/components/<_file..>", rank = 1)] fn components(_file: PathBuf) -> Template { - not_found() + not_found_locale(ENGLISH.into()) +} + +#[get("//components/<_file..>", rank = 11)] +fn components_locale(locale: SupportedLocale, _file: PathBuf) -> Template { + not_found_locale(locale.0) } #[get("/logos/", rank = 1)] @@ -204,7 +210,21 @@ fn redirect_locale(_locale: redirect::Locale, dest: redirect::Destination) -> Re } #[catch(404)] -fn not_found() -> Template { +fn not_found(req: &Request) -> Template { + let lang = if let Some(next) = req.uri().segments().next() { + if let Ok(lang) = SupportedLocale::from_param(RawStr::from_str(next)) { + lang.0 + } else { + ENGLISH.into() + } + } else { + ENGLISH.into() + }; + + not_found_locale(lang) +} + +fn not_found_locale(lang: String) -> Template { let page = "404"; let title = format!("{} - Rust programming language", page).to_string(); let context = Context { @@ -213,7 +233,7 @@ fn not_found() -> Template { parent: LAYOUT.to_string(), is_landing: false, data: (), - lang: ENGLISH.to_string(), + lang, baseurl: String::new(), pontoon_enabled: pontoon_enabled(), }; @@ -222,7 +242,7 @@ fn not_found() -> Template { #[catch(500)] fn catch_error() -> Template { - not_found() + not_found_locale(ENGLISH.into()) } fn compile_sass(filename: &str) { @@ -420,6 +440,7 @@ fn main() { team_locale, production_locale, subject_locale, + components_locale, redirect, redirect_pdfs, redirect_bare_en_us, diff --git a/templates/404.hbs b/templates/404.hbs index 31d8fc460..15b865e7e 100644 --- a/templates/404.hbs +++ b/templates/404.hbs @@ -3,11 +3,11 @@
-

404

-

Whoops, this page doesn’t exist :-(

+

{{text error404-page-title}}

+

{{text error404-subtitle}}

- 404 not found image + {{text error404-img-alt}}
diff --git a/templates/components/panels/language-values.hbs b/templates/components/panels/language-values.hbs index 1baa00cb0..e21bacdab 100644 --- a/templates/components/panels/language-values.hbs +++ b/templates/components/panels/language-values.hbs @@ -2,7 +2,7 @@

- {{text language-values-why-rust}} + {{text why-rust}}

diff --git a/templates/components/what/cli/example.hbs b/templates/components/what/cli/example.hbs index f101bc0d8..ec50faa64 100644 --- a/templates/components/what/cli/example.hbs +++ b/templates/components/what/cli/example.hbs @@ -1,7 +1,7 @@
-

{{text cli-example-heading}}

+

{{text get-started-exclamation}}

diff --git a/templates/components/what/cli/pitch.hbs b/templates/components/what/cli/pitch.hbs index 789d23c1a..8ce9d7a5b 100644 --- a/templates/components/what/cli/pitch.hbs +++ b/templates/components/what/cli/pitch.hbs @@ -2,7 +2,7 @@

- {{text cli-pitch-heading}} + {{text why-rust}}

diff --git a/templates/components/what/cli/production.hbs b/templates/components/what/cli/production.hbs index fc4ca310b..8e91dbc31 100644 --- a/templates/components/what/cli/production.hbs +++ b/templates/components/what/cli/production.hbs @@ -1,7 +1,7 @@
-

{{text cli-production-heading}}

+

{{text production-use}}

diff --git a/templates/components/what/embedded/get-started.hbs b/templates/components/what/embedded/get-started.hbs index 1da4fd868..c60b7eea2 100644 --- a/templates/components/what/embedded/get-started.hbs +++ b/templates/components/what/embedded/get-started.hbs @@ -1,48 +1,47 @@
-

Get started!

+

{{text get-started-exclamation}}

- DIP-6 package
-

The Discovery book

+

{{text embedded-get-started-discovery-book-heading}}

- Learn embedded development from the ground up—using Rust! + {{text embedded-get-started-discovery-book-description}}

- Read + {{text embedded-get-started-read-link}}
- TFQP-16 package
-

The Embedded Rust book

+

{{text embedded-get-started-embedded-rust-book-heading}}

- Already familiar with Embedded development? - Jump in with Rust and start reaping the benefits. + {{text embedded-get-started-embedded-rust-book-description}}

- Read + {{text embedded-get-started-read-link}}
- BGA package
-

The Embedonomicon

+

{{text embedded-get-started-embedonomicon-heading}}

- Look under the hood of foundational embedded libraries. + {{text embedded-get-started-embedonomicon-description}}

- Read + {{text embedded-get-started-read-link}}
@@ -50,7 +49,7 @@
diff --git a/templates/components/what/embedded/pitch.hbs b/templates/components/what/embedded/pitch.hbs index 37a5aaeca..d5235e849 100644 --- a/templates/components/what/embedded/pitch.hbs +++ b/templates/components/what/embedded/pitch.hbs @@ -2,7 +2,7 @@

- Why Rust? + {{text why-rust}}

@@ -10,53 +10,51 @@
- A microscope

- Powerful static analysis + {{text embedded-pitch-analysis-heading}}

- Enforce pin and peripheral configuration at compile time. Guarantee that resources won’t be used by unintended parts of your application. + {{text embedded-pitch-analysis-description}}

- Learn more + {{text embedded-learn-more-link}}
- A RAM stick

- Flexible memory + {{text embedded-pitch-memory-heading}}

- Dynamic memory allocation is optional. Use a global allocator and dynamic data structures. - Or leave out the heap altogether and statically allocate everything. + {{text embedded-pitch-memory-description}}

- Learn more + {{text embedded-learn-more-link}}
- Gears

- Fearless concurrency + {{text embedded-pitch-concurrency-heading}}

- Rust makes it impossible to accidentally share state between threads. - Use any concurrency approach you like, and you’ll still get Rust’s strong guarantees. + {{text embedded-pitch-concurrency-description}}

- Learn more + {{text embedded-learn-more-link}}
@@ -64,46 +62,44 @@
- Handshake

- Interoperability + {{text embedded-pitch-interop-heading}}

- Integrate Rust into your existing C codebase or leverage an existing SDK to write a Rust - application. + {{text embedded-pitch-interop-description}}

- Learn more + {{text embedded-learn-more-link}}
- Luggage trolley
-

Portability

+

{{text embedded-pitch-portability-heading}}

- Write a library or driver once, and use it with a variety of systems, ranging - from very small microcontrollers to powerful SBCs. + {{text embedded-pitch-portability-description}}

- Learn more + {{text embedded-learn-more-link}}
- Shield Logo + {{text embedded-pitch-community-alt}}
-

Community driven

+

{{text embedded-pitch-community-heading}}

- As part of the Rust open source project, support for embedded systems is driven by a best-in-class open source community, with support from commercial partners. + {{text embedded-pitch-community-description}}

- Learn more + {{text embedded-learn-more-link}}
diff --git a/templates/components/what/embedded/showcase.hbs b/templates/components/what/embedded/showcase.hbs index 2445f603d..4c4960530 100644 --- a/templates/components/what/embedded/showcase.hbs +++ b/templates/components/what/embedded/showcase.hbs @@ -1,23 +1,23 @@