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

Allow specifying the wanted compression formats at runtime #105

Merged
merged 6 commits into from
Dec 10, 2020

Conversation

pietroalbini
Copy link
Member

@pietroalbini pietroalbini commented Dec 10, 2020

This PR adds the --compression-formats option to the generate, combine and tarball subcommands, allowing to choose one or more output formats to generate. If the flag is not present the default set of formats is generated (gz and xz):

cargo run -- generate --compression-formats=xz ...
cargo run -- generate --compression-formats=gz,xz ...

The combine subcommand is also tweaked to allow combining tarballs compressed using any of the supported formats, instead of only allowing gzip-compressed tarballs.

All of this will allow rustc's CI to choose which formats to generate, and it will allow to easily add new formats in the future.

This PR can be reviewed commit-by-commit.
r? @alexcrichton

Copy link
Member

@alexcrichton alexcrichton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great!

@pietroalbini pietroalbini merged commit 5254dbf into master Dec 10, 2020
@pietroalbini pietroalbini deleted the dynamic-compression branch December 10, 2020 16:54
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