Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Composer ask me for update every time

Tags:

composer-php

When I try to do:

$ sudo php composer.phar update

I get this warning:

Warning: This development build of composer is over 30 days old. It is recommended to update it by running "composer.phar self-update" to get the latest version.

When I type:

$ sudo php composer.phar self-update
$ sudo php composer.phar update

the warning disappear, but the next time I want to execute the same command (not after 30 days), the warning comes again. How can I solve it?

like image 470
Manolo Avatar asked Sep 11 '13 13:09

Manolo


1 Answers

My guess is that something else overwrites your composer.phar with an old copy. If the self-update process was failing, then you would still see the warning when doing an update right after. If you don't then something must be happening in the meantime.

You can use php composer.phar -V to see the exact version of the phar you have. You could check after a self-update and check after a while again to see if the version changed. Maybe it's checked out in git or you have a build process reverting it or something?

like image 182
Seldaek Avatar answered Sep 24 '22 14:09

Seldaek