Trusted Publishing for imxrt-rs packages

2026-04-12


I enabled Trusted Publishing on a few imxrt-rs packages

  • imxrt-dma
  • imxrt-usbd
  • imxrt-ral

in preparation for the imxrt-hal 0.6 release. I'll do the same for imxrt-hal, once it's ready for releasing.

I've wanted some kind of publishing automation for a while, and Trusted Publishing made the "get it in crates.io" step easy. Until now, I've been saying cargo publish from my development hosts. Other maintainers could also say cargo publish if they're in the imxrt-rs/owners GitHub team. However, it's neither automated nor obvious to users where these releases are coming from.

Now, the only way to publish these packages to crates.io is through Trusted Publishing, from GitHub. Maintainers cannot say cargo publish anymore (unless we uncheck a box). This may make the imxrt-rs/owners package owners redundant, so I should figure out if it should stick around.

It's better, but still not as automated as I'd like. Here's roughly how to publish the package:

  1. Make sure whatever commit you're tagging has passed CI workflows.
  2. Tag the commit, and push it to GitHub.
  3. Create a GitHub release for that tag.

I'd eventually like the release workflow to make sure all the other workflows have passed, automating step 1. If you know of a good way to do this, I'd appreciate tips.