Skip to content

Bootstrap temporary Composer for local project creation - #1305

Draft
Soner (shyim) with Copilot wants to merge 2 commits into
mainfrom
copilot/project-create-bootstrap-composer
Draft

Bootstrap temporary Composer for local project creation#1305
Soner (shyim) with Copilot wants to merge 2 commits into
mainfrom
copilot/project-create-bootstrap-composer

Conversation

Copilot AI commented Jul 31, 2026

Copy link
Copy Markdown
Contributor

What changed?

  • Added a verified, command-scoped Composer resolver for local project creation.
    • Uses composer from PATH when available.
    • Otherwise downloads and verifies Composer’s official installer, creates a temporary PHAR, and removes all artifacts on exit.
  • Executes temporary Composer through the resolved PHP binary.
  • Allows project create preflight without global Composer; PHP compatibility remains required.
  • Preserves Docker and existing global-Composer behavior.
<selected-php> <temporary-dir>/composer.phar install --no-interaction

Why?

Local project creation failed on hosts with PHP but no globally available Composer. The fallback avoids global installation and does not persist Composer artifacts in the project or user directories.

How was this tested?

  • Added resolver tests for global resolution, verified bootstrap, checksum/status failures, cancellation, cleanup, and PHP/PHAR invocation.
  • Ran go test ./... and go vet ./internal/system ./cmd/project.

Related issue or discussion

Copilot AI changed the title [WIP] Add temporary Composer bootstrap for local project creation Bootstrap temporary Composer for local project creation Jul 31, 2026
Copilot AI requested a review from Soner (shyim) July 31, 2026 11:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

project create: bootstrap Composer temporarily when it is not installed globally

3 participants