Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to get composer to update version numbers to the latest ones available in composer.json?

Tags:

composer-php

In my composer.json config file, I have:

"require": {
    "zendframework/zend-log" : "~2.3",
 },
"require-dev": {
    "phpunit/phpunit": "^5.4"
 } 

I want:

"require": {
   "zendframework/zend-log" : "^2.9",
},
"require-dev": {
    "phpunit/phpunit": "^6.2"
 } 

Note the version number changes

How? I want it to be done automatically without me having to look up each individual latest version that's available and edit it manually.

There is this question but it does not help: How to resolve package not found error when trying to make the composer get the latest package versions?

like image 929
Dennis Avatar asked Jul 19 '17 17:07

Dennis


Video Answer


1 Answers

Run

composer require zendframework/zend-log

and

composer require --dev phpunit/phpunit
like image 138
kuba Avatar answered Oct 16 '22 22:10

kuba