kornelski / cargo-deb

A cargo subcommand that generates Debian packages from information in Cargo.toml
https://lib.rs/cargo-deb
MIT License
404 stars 48 forks source link

Support switching between xz and gzip formats at runtime #96

Closed scootermon closed 1 year ago

scootermon commented 1 year ago

My use case for this is an embedded linux system that doesn't support LZMA compression. Right now this can be achieved by building cargo-deb with default features disabled, but this also removes the option of using LZMA for systems that support it.

I would like to have an option akin to fpm's --deb-compression flag that allows me to explicitly select the compression when building the package.

I'm happy to contribute this feature, but I would like to get some guidance on the preferred approach. The way I see it, this should be a command line option, but I'm also fine with having it as a field in the cargo.metadata.deb config.

kornelski commented 1 year ago

Yes, having a command line option for this is a good idea.