fix(cli): pass --all-features flag to cargo (#5153)
This commit is contained in:
1 parent
02b62342ef
commit
2ee8ecd477
1 file changed
+7
@@ -388,6 +388,7 @@ pub(crate) struct BuildRequest {
|
|||||||
pub(crate) extra_cargo_args: Vec<String>,
|
pub(crate) extra_cargo_args: Vec<String>,
|
||||||
pub(crate) extra_rustc_args: Vec<String>,
|
pub(crate) extra_rustc_args: Vec<String>,
|
||||||
pub(crate) no_default_features: bool,
|
pub(crate) no_default_features: bool,
|
||||||
|
pub(crate) all_features: bool,
|
||||||
pub(crate) target_dir: PathBuf,
|
pub(crate) target_dir: PathBuf,
|
||||||
pub(crate) skip_assets: bool,
|
pub(crate) skip_assets: bool,
|
||||||
pub(crate) wasm_split: bool,
|
pub(crate) wasm_split: bool,
|
||||||
@@ -605,6 +606,7 @@ impl BuildRequest {
|
|||||||
*/
|
*/
|
||||||
let mut features = args.features.clone();
|
let mut features = args.features.clone();
|
||||||
let mut no_default_features = args.no_default_features;
|
let mut no_default_features = args.no_default_features;
|
||||||
|
let all_features = args.all_features;
|
||||||
let mut triple = args.target.clone();
|
let mut triple = args.target.clone();
|
||||||
let mut renderer = args.renderer;
|
let mut renderer = args.renderer;
|
||||||
let mut bundle_format = args.bundle;
|
let mut bundle_format = args.bundle;
|
||||||
@@ -986,6 +988,7 @@ impl BuildRequest {
|
|||||||
features,
|
features,
|
||||||
bundle,
|
bundle,
|
||||||
no_default_features,
|
no_default_features,
|
||||||
|
all_features,
|
||||||
crate_package,
|
crate_package,
|
||||||
crate_target,
|
crate_target,
|
||||||
profile,
|
profile,
|
||||||
@@ -2612,6 +2615,10 @@ impl BuildRequest {
|
|||||||
cargo_args.push("--no-default-features".to_string());
|
cargo_args.push("--no-default-features".to_string());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if self.all_features {
|
||||||
|
cargo_args.push("--all-features".to_string());
|
||||||
|
}
|
||||||
|
|
||||||
if !self.features.is_empty() {
|
if !self.features.is_empty() {
|
||||||
cargo_args.push("--features".to_string());
|
cargo_args.push("--features".to_string());
|
||||||
cargo_args.push(self.features.join(" "));
|
cargo_args.push(self.features.join(" "));
|
||||||
|
|||||||
Reference in new issue
Block a user