diff options
| author | nsfisis <nsfisis@gmail.com> | 2026-05-02 17:30:27 +0900 |
|---|---|---|
| committer | nsfisis <nsfisis@gmail.com> | 2026-05-02 17:30:27 +0900 |
| commit | 99a33b951502d3e80eb70f53551413b9dc0f4d6c (patch) | |
| tree | 9716d7ac568070032ea7b3141b6763c3443c4589 /crates/mozart/src/commands/create_project.rs | |
| parent | 43efd895d24b7ccd2853fa5bcf08ad0e621f33ce (diff) | |
| download | php-mozart-99a33b951502d3e80eb70f53551413b9dc0f4d6c.tar.gz php-mozart-99a33b951502d3e80eb70f53551413b9dc0f4d6c.tar.zst php-mozart-99a33b951502d3e80eb70f53551413b9dc0f4d6c.zip | |
refactor(commands): split install/update into CLI execute + library run
Carve commands::install::execute and commands::update::execute into thin
CLI-arg-driven wrappers + run() entry points that take (working_dir,
args, console, repositories, executor) directly. The wrappers build a
production RepositorySet (Packagist) + FilesystemExecutor from cli, then
dispatch to run; in-process tests will call run directly with an empty
RepositorySet (Composer's `'packagist' => false` test config) and a
tracing InstallerExecutor.
The install -> update fallback (no composer.lock present) now goes
through update::run, forwarding the caller's repositories + executor so
test mocks survive the edge.
Also drop the now-dead InstallConfig::no_cache field — install_from_lock
stopped consuming the cache when FilesystemExecutor was extracted in the
earlier DI plumbing pass, so the field has no effect.
All 136 enabled installer fixtures + 114 mozart-registry tests + 541
mozart lib tests still green; clippy clean.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Diffstat (limited to 'crates/mozart/src/commands/create_project.rs')
| -rw-r--r-- | crates/mozart/src/commands/create_project.rs | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/crates/mozart/src/commands/create_project.rs b/crates/mozart/src/commands/create_project.rs index 01b337e..c2c4f92 100644 --- a/crates/mozart/src/commands/create_project.rs +++ b/crates/mozart/src/commands/create_project.rs @@ -522,7 +522,6 @@ pub async fn execute( apcu_autoloader_prefix: None, download_only: false, prefer_source: args.prefer_source, - no_cache: cli.no_cache, }, console, &mut executor, |
