diff options
| author | nsfisis <nsfisis@gmail.com> | 2026-07-06 23:54:52 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2026-07-06 23:54:52 +0900 |
| commit | 6ab39f42fc5bf05b29f24e315bf3088513b0f626 (patch) | |
| tree | 165724b8db246961727ac5176422b2d7168453b5 /crates/shirabe/src | |
| parent | 7f24ec418432a66da451b7c83042185dca42da9c (diff) | |
| download | php-shirabe-main.tar.gz php-shirabe-main.tar.zst php-shirabe-main.zip | |
BaseConfigCommand::initialize skipped the parent BaseCommand::initialize
chain (plugin enable/disable resolution, PRE_COMMAND_RUN event dispatch,
COMPOSER_NO_* env option overrides), unlike PHP's parent::initialize()
call. The trait-disambiguation blocker cited in the old TODO was already
solved elsewhere via the base_command_initialize free function; wire it
in here too so ConfigCommand and RepositoryCommand match PHP behavior.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Diffstat (limited to 'crates/shirabe/src')
| -rw-r--r-- | crates/shirabe/src/command/base_config_command.rs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/crates/shirabe/src/command/base_config_command.rs b/crates/shirabe/src/command/base_config_command.rs index b218961..a2a51d4 100644 --- a/crates/shirabe/src/command/base_config_command.rs +++ b/crates/shirabe/src/command/base_config_command.rs @@ -1,6 +1,7 @@ //! ref: composer/src/Composer/Command/BaseConfigCommand.php use crate::command::BaseCommand; +use crate::command::base_command::base_command_initialize; use crate::config::Config; use crate::config::JsonConfigSource; use crate::factory::Factory; @@ -23,9 +24,11 @@ pub trait BaseConfigCommand: BaseCommand { &self, input: std::rc::Rc<std::cell::RefCell<dyn InputInterface>>, output: std::rc::Rc<std::cell::RefCell<dyn OutputInterface>>, - ) -> anyhow::Result<()> { - // TODO(phase-b): BaseCommand::initialize chained via Self::initialize would recurse; - // omitted until trait disambiguation is sorted. + ) -> anyhow::Result<()> + where + Self: Sized, + { + base_command_initialize(self, input.clone(), output.clone())?; if input .borrow() |
