pun update
Update dependencies.
Update every package, or only the ones named, then install them. The lock matches composer update.
Usage
pun update [packages] [options]
pun update
pun update laravel/framework
pun update 'symfony/*' --with-dependencies
pun update --dry-run
Options
| Option | Description |
|---|---|
-w, --with-dependencies |
Also update their dependencies. |
-W, --with-all-dependencies |
Also update their dependencies, including your own requirements. |
-m, --minimal-changes |
Keep other packages at their locked version where possible. |
--prefer-lowest |
Pick the lowest allowed versions. |
--prefer-stable |
Prefer stable versions. |
--dry-run |
Show the changes, write nothing. |
--no-install |
Write the lock, leave vendor/ alone. |
Update also takes every pun install option.
What happens
- Reads Packagist and the
composer,packageandpathrepositories incomposer.json. - Picks the newest versions that fit
composer.jsonand this PHP. - Writes
composer.lock, then runspun install. - Runs
pre-update-cmdandpost-update-cmd. - If requirements clash, lists the conflicts and writes nothing.
Exit codes
| Code | Meaning |
|---|---|
| 0 | Updated, or nothing to change. |
| 2 | No composer.json, requirements that clash, or a failed install. |