Skip to content

chore: don't ship composer.lock in the starter - #9

Open
vipertecpro wants to merge 1 commit into
NativePHP:mainfrom
vipertecpro:fix/composer-install-out-of-box
Open

chore: don't ship composer.lock in the starter#9
vipertecpro wants to merge 1 commit into
NativePHP:mainfrom
vipertecpro:fix/composer-install-out-of-box

Conversation

@vipertecpro

@vipertecpro vipertecpro commented Aug 2, 2026

Copy link
Copy Markdown
Contributor

What

Remove the committed composer.lock from the starter so a fresh clone installs cleanly:

git clone git@github.com:NativePHP/mobile-starter.git && cd mobile-starter
composer install

Why

composer install reads download URLs straight from composer.lock, and the committed lock pinned nativephp/mobile-ui to the private plugins registry — so a fresh clone without registry credentials hit an auth prompt on the very first install.

Rather than keep regenerating a pinned lock, this follows the standard skeleton convention (e.g. laravel/laravel ships no composer.lock): a starter is a template, so each new project should resolve its dependencies fresh from their current sources at creation time. mobile-ui is now on public Packagist, so a fresh resolve pulls it (and everything else) with no auth. The lock then becomes the derived project's responsibility, which is where it belongs.

Change

  • Remove composer.lock.
  • composer.json is untouched — the nativephp-plugins repository block stays in place for premium plugins.

Verified

Fresh clone with no credentials configured → composer install resolves and installs cleanly, mobile-ui pulled from public GitHub.

🤖 Generated with Claude Code

@vipertecpro
vipertecpro marked this pull request as ready for review August 2, 2026 05:22
Comment thread composer.json
@vipertecpro
vipertecpro force-pushed the fix/composer-install-out-of-box branch from 5f047d9 to f75053c Compare August 2, 2026 05:31
@vipertecpro vipertecpro changed the title fix: make composer install work out of the box on a fresh clone fix: regenerate composer.lock so a fresh composer install needs no auth Aug 2, 2026
Remove the committed composer.lock so a fresh clone resolves dependencies
from their current sources instead of a pinned (and now stale) lock file.
This matches the skeleton convention (laravel/laravel ships no lock) and
fixes a fresh 'composer install' prompting for auth on nativephp/mobile-ui,
which is now published on public Packagist. The nativephp-plugins
repository block stays in place for premium plugins; the lock becomes the
derived project's responsibility.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@vipertecpro
vipertecpro force-pushed the fix/composer-install-out-of-box branch from f75053c to 924fcdb Compare August 2, 2026 05:55
@vipertecpro vipertecpro changed the title fix: regenerate composer.lock so a fresh composer install needs no auth chore: don't ship composer.lock in the starter Aug 2, 2026
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.

2 participants