diff options
| author | nsfisis <nsfisis@gmail.com> | 2026-06-12 01:01:35 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2026-06-12 01:01:43 +0900 |
| commit | 1e44f5723e4c0e0903d00a61f254901e612fe5e1 (patch) | |
| tree | 9c2e1eec364bbf6418a4072ee7767b04c3df0297 /crates/shirabe/src/command/install_command.rs | |
| parent | ddf0a624145b618c05c2ee47414545b99b685f37 (diff) | |
| download | php-shirabe-1e44f5723e4c0e0903d00a61f254901e612fe5e1.tar.gz php-shirabe-1e44f5723e4c0e0903d00a61f254901e612fe5e1.tar.zst php-shirabe-1e44f5723e4c0e0903d00a61f254901e612fe5e1.zip | |
feat(symfony-console): port Symfony Console and make the workspace compile
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Diffstat (limited to 'crates/shirabe/src/command/install_command.rs')
| -rw-r--r-- | crates/shirabe/src/command/install_command.rs | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/crates/shirabe/src/command/install_command.rs b/crates/shirabe/src/command/install_command.rs index f491820..182f855 100644 --- a/crates/shirabe/src/command/install_command.rs +++ b/crates/shirabe/src/command/install_command.rs @@ -69,19 +69,19 @@ impl InstallCommand { ) -> Result<i64> { let io = self.get_io().clone(); - if input.borrow().get_option("dev").as_bool().unwrap_or(false) { + if input.borrow().get_option("dev")?.as_bool().unwrap_or(false) { io.write_error("<warning>You are using the deprecated option \"--dev\". It has no effect and will break in Composer 3.</warning>"); } if input .borrow() - .get_option("no-suggest") + .get_option("no-suggest")? .as_bool() .unwrap_or(false) { io.write_error("<warning>You are using the deprecated option \"--no-suggest\". It has no effect and will break in Composer 3.</warning>"); } - let args = input.borrow().get_argument("packages"); + let args = input.borrow().get_argument("packages")?; let args_vec: Vec<String> = args .as_list() .map(|l| { @@ -101,7 +101,7 @@ impl InstallCommand { if input .borrow() - .get_option("no-install") + .get_option("no-install")? .as_bool() .unwrap_or(false) { @@ -132,7 +132,7 @@ impl InstallCommand { let optimize = input .borrow() - .get_option("optimize-autoloader") + .get_option("optimize-autoloader")? .as_bool() .unwrap_or(false) || config @@ -142,7 +142,7 @@ impl InstallCommand { .unwrap_or(false); let authoritative = input .borrow() - .get_option("classmap-authoritative") + .get_option("classmap-authoritative")? .as_bool() .unwrap_or(false) || config @@ -152,13 +152,13 @@ impl InstallCommand { .unwrap_or(false); let apcu_prefix = input .borrow() - .get_option("apcu-autoloader-prefix") + .get_option("apcu-autoloader-prefix")? .as_string() .map(|s| s.to_string()); let apcu = apcu_prefix.is_some() || input .borrow() - .get_option("apcu-autoloader") + .get_option("apcu-autoloader")? .as_bool() .unwrap_or(false) || config @@ -173,7 +173,7 @@ impl InstallCommand { .set_output_progress( !input .borrow() - .get_option("no-progress") + .get_option("no-progress")? .as_bool() .unwrap_or(false), ); @@ -182,21 +182,21 @@ impl InstallCommand { .set_dry_run( input .borrow() - .get_option("dry-run") + .get_option("dry-run")? .as_bool() .unwrap_or(false), ) .set_download_only( input .borrow() - .get_option("download-only") + .get_option("download-only")? .as_bool() .unwrap_or(false), ) .set_verbose( input .borrow() - .get_option("verbose") + .get_option("verbose")? .as_bool() .unwrap_or(false), ) @@ -205,14 +205,14 @@ impl InstallCommand { .set_dev_mode( !input .borrow() - .get_option("no-dev") + .get_option("no-dev")? .as_bool() .unwrap_or(false), ) .set_dump_autoloader( !input .borrow() - .get_option("no-autoloader") + .get_option("no-autoloader")? .as_bool() .unwrap_or(false), ) @@ -226,14 +226,14 @@ impl InstallCommand { .set_error_on_audit( input .borrow() - .get_option("audit") + .get_option("audit")? .as_bool() .unwrap_or(false), ); if input .borrow() - .get_option("no-plugins") + .get_option("no-plugins")? .as_bool() .unwrap_or(false) { |
