cargo-publish-all 0.1.0

Tool to publish all packages
Documentation

cargo-publish-all

Warning: This tool is completely untested and may not behave correctly. Use at your own risk.

This tool scans the current workspace, builds every package as if it was published and publishes the ones that do not exist yet on crates.io. If at any point the validation fails it will stop.

Validation consists of two phases:

  1. Package & normalize all packages; inject replace sections for crates that will be published and try building every package.
  2. If the first pass succeeds, publish all packages in the correct order. This will verify a second time, and should ideally never fail. However, it's better to be safe.

If an error is only detected in phase 2 (which should not happen), half of the workspace will be published (and build successfully), the other half won't be on crates.io. This is definitely better than having broken packages on crates.io.

TODO:

  • Pass args on to cargo
  • Proper logging, no use of println!
  • show how versions are bumped (0.1.2 -> 0.1.3)
    • bumping older versions (how to display this?)
  • better errors
  • better validation
    • can we use package names as they are used?
    • correct versions referenced
  • try merging this into Cargo
    • maybe too opinionated?