mdbook-i18n-helpers icon indicating copy to clipboard operation
mdbook-i18n-helpers copied to clipboard

Update to mdbook 0.5

Open ehuss opened this issue 1 month ago • 2 comments

This is a preliminary PR for updating mdbook-i18n-helpers to mdbook 0.5. This should wait until at least mdbook 0.5 is released.

I haven't had a chance to do much testing, but the basics seem to work.

There is a migration guide that explains all the changes in the release.

ehuss avatar Oct 29 '25 01:10 ehuss

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

google-cla[bot] avatar Oct 29 '25 01:10 google-cla[bot]

Please update the relevant changelogs too.

qwandor avatar Oct 29 '25 10:10 qwandor

Codecov Report

:x: Patch coverage is 18.51852% with 22 lines in your changes missing coverage. Please review. :white_check_mark: Project coverage is 85.53%. Comparing base (886f15e) to head (191312f). :warning: Report is 35 commits behind head on main.

Files with missing lines Patch % Lines
i18n-helpers/src/preprocessors/gettext.rs 0.00% 7 Missing :warning:
fuzz/src/lib.rs 0.00% 6 Missing :warning:
i18n-helpers/src/bin/mdbook-gettext.rs 0.00% 4 Missing :warning:
i18n-helpers/src/xgettext.rs 71.42% 0 Missing and 2 partials :warning:
mdbook-tera-backend/src/main.rs 0.00% 2 Missing :warning:
mdbook-tera-backend/src/tera_renderer/renderer.rs 0.00% 0 Missing and 1 partial :warning:
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #284      +/-   ##
==========================================
+ Coverage   84.74%   85.53%   +0.78%     
==========================================
  Files          15       17       +2     
  Lines        3377     3339      -38     
  Branches     3377     3339      -38     
==========================================
- Hits         2862     2856       -6     
+ Misses        413      381      -32     
  Partials      102      102              

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

codecov-commenter avatar Nov 18 '25 00:11 codecov-commenter

This looks reasonable and the tests pass, have you had a chance to do much manual testing?

qwandor avatar Nov 18 '25 01:11 qwandor

I have not done significant testing. I mainly verified that a local copy of comprehensive-rust and rust-by-example worked with the mdbook-gettext preprocessor. The different languages seemed to appear as I expected. I also verified that mdbook-xgettext was able to extract the po files, but I didn't go beyond that.

If you have suggestions for more things for me to try, I'd be happy to do that. I wasn't really sure what to try.

ehuss avatar Nov 18 '25 02:11 ehuss