Skip to content

Latest commit

 

History

History
49 lines (38 loc) · 2.34 KB

composer.md

File metadata and controls

49 lines (38 loc) · 2.34 KB
title category layout weight authors updated description
composer
CLI
2017/sheet
-1
github
benolot
2018-03-06
Basic guide on how to use Composer, the PHP Package manager.

All composer commands, depending on your install, may need to use php composer.phar in the install folder for composer, instead of plain composer.

Package management

Command Description
composer install Install everything in composer.json
--- ---
composer install laravel Install a package
composer install laravel --dry-run Simulates the install without installing anything
composer install laravel --no-scripts Skips post-download scripts

Updating

Command Description
composer update Update all packages
--- ---
composer update laravel Update a certain package
composer update vendor/* Update all packages in a folder
composer update --lock Update lock file hash without updating any packages

Requiring

Command Description
composer require laravel. Add new package to composer.json and install it
--- ---
composer require laravel --dev Add new package to require-dev and install it.

Removing

Command Description
composer remove laravel Remove new package from composer.json and uninstall it