feat: update depot version to 0.20.0 and add --install-deps flag for automatic dependency installation
This commit is contained in:
+13
@@ -93,6 +93,10 @@ pub enum Commands {
|
||||
/// Install package to rootfs after creating package archive(s)
|
||||
#[arg(long)]
|
||||
install: bool,
|
||||
|
||||
/// Automatically install missing dependencies before building
|
||||
#[arg(long)]
|
||||
install_deps: bool,
|
||||
},
|
||||
/// Update installed packages from configured repositories
|
||||
Update {
|
||||
@@ -347,4 +351,13 @@ mod tests {
|
||||
let cli = Cli::try_parse_from(["depot", "--test-deps", "install", "foo"]).unwrap();
|
||||
assert!(cli.test_deps);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn build_install_deps_flag_is_parsed() {
|
||||
let cli = Cli::try_parse_from(["depot", "build", "--install-deps", "pkg.toml"]).unwrap();
|
||||
match cli.command {
|
||||
Commands::Build { install_deps, .. } => assert!(install_deps),
|
||||
_ => panic!("expected build command"),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user