This repository was archived by the owner on Aug 31, 2023. It is now read-only.
fix(rome_bin): fix the parsing of the internal CLI arguments for the daemon server in debug mode #3068
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
The
rome_bin
distribution is temporarily using "internal" arguments starting with__
to control the daemon server process, but thepico_args
library forbids argument names from starting with anything other than-
in debug mode. I modified the parsing logic to use a subcommand instead of an argument, since those do not have the same naming restrictions.Test Plan
This change sits at the very top-level of the entire binary distribution, so it's not really easily testable except by first building the CLI then having the tests actually run the resulting binary. Not impossible, but for now I've just manually run
cargo rome-cli-dev __run_server
and checked that it didn't panic on start