Home >Development Tools >composer >The use of composer.lock under composer and how to delete it
The following tutorial column of composer will introduce the use of composer.lock under composer and how to delete it. I hope it will be helpful to friends in need!
composer.lock records the versions of all currently installed PHP components. If multiple people need to keep the version of the downloaded PHP components during collaborative development to reduce unnecessary trouble, then composer.lock needs to be added to version control. , such as using git or svn, then you need to add it to version control.
No need to do otherwise.
It should be noted that when composer installmakes component dependencies, the composer.lock file will not be updated unless new components are introduced into composer.json. If you want to update Please use composer update will update the component to the latest stable version and also update the latest composer.lock file.
Refresh the composer.lock file
composer update nothing
or
composer update --lock
The above is the detailed content of The use of composer.lock under composer and how to delete it. For more information, please follow other related articles on the PHP Chinese website!