Rename --feature to --features and support TYPST_FEATURES env var (#5523)

This commit is contained in:
Laurenz 2024-12-04 18:42:59 +01:00 committed by GitHub
parent 60f1d8f9b5
commit 4f3ba7f8ca
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 3 deletions

View File

@ -315,8 +315,8 @@ pub struct ProcessArgs {
/// Enables in-development features that may be changed or removed at any
/// time.
#[arg(long = "feature", value_delimiter = ',')]
pub feature: Vec<Feature>,
#[arg(long = "features", value_delimiter = ',', env = "TYPST_FEATURES")]
pub features: Vec<Feature>,
/// The format to emit diagnostics in.
#[clap(long, default_value_t)]

View File

@ -117,7 +117,7 @@ impl SystemWorld {
.collect();
let features = process_args
.feature
.features
.iter()
.map(|&feature| match feature {
Feature::Html => typst::Feature::Html,