composer init
composer create-project vendor/package:version
composer install --no-dev -a
(–classmap-authoritative)composer require vendor/package:version
composer require --dev vendor/package:version
Example version constraints @dev
, ^1.0
, ~1.1.0
composer remove vendor/package
composer update --dry-run
composer update --lock
composer update "vendor/package"
composer update "vendor/*" --with-dependencies
composer update "vendor/prefix-*" --with-all-dependencies
composer outdated -D -m --strict --locked
--dev
Require a dev package--dry-run
Just show what composer would do--ignore-platform-reqs
Ignores platform dependencies as PHP Version and extensions--with-dependencies
Update also dependencies of packages in the argument list, except those which are root requirements.--with-all-dependencies
Update also dependencies of packages in the argument list, including those which are root requirements.composer why
composer fund
composer config minimum-stability dev
composer config prefer-stable true
composer show
composer config gitlab-domains gitlab.my.org
composer config repositories.local '{"type": "path", "url": "packages/*", "options": {"reference": "none"}}'
composer bump
What should work vs. what is currently installed.
The composer.json defines the packages you want to install and their version range that should work.
The composer.lock pins the current install packages, their version and all dependencies of the packages with their version (dependency tree).
Composer
VCS
Package
Path
*
and ?
.options.ssl.cafile
, trust a ca certificate during the communication with the https repository