Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Skip some untranslatable code blocks #1258

Merged
merged 1 commit into from
Sep 26, 2023
Merged

Conversation

mgeisler
Copy link
Collaborator

@mgeisler mgeisler commented Sep 26, 2023

This builds on the work of @dyoo in
google/mdbook-i18n-helpers#69: by adding a special <!-- mdbook-xgettext: skip --> comment, we can skip the following code block.

I also modified a few code blocks to remove translatable text: variable names are not expected to be translated, so it’s fine to have a line with println!("foo: {foo}") in the code block.

This PR removes 36 messages from the POT file. The number of lines drop by 633 (3%).

Part of #1257.

This builds on the work of @dyoo in
google/mdbook-i18n-helpers#69: by adding a
special `<!-- mdbook-xgettext: skip -->` comment, we can skip the
following code block.

I also modified a few code blocks to remove translatable text:
variable names are not expected to be translated, so it’s fine to have
a line with `println!("foo: {foo}")` in the code block.

Part of #1257.
@mgeisler mgeisler merged commit d0e0e5c into main Sep 26, 2023
33 checks passed
@mgeisler mgeisler deleted the skip-untranslatable-code-blocks branch September 26, 2023 15:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants