DEV Community

loading...
Cover image for Downgrade composer from 2.x to 1.x via brew

Downgrade composer from 2.x to 1.x via brew

saschaeggi profile image Sascha Eggenberger Originally published at saschaeggi.Medium Updated on ・1 min read

You just upgraded your brew packages and composer updated itself to version 2.x but you still need version 1.x? This is how you can downgrade (& upgrade again):

Show available versions of composer:

brew log composer

For me the latest 1.x version to date is: composer 1.10.15

Let's downgrade

composer self-update 1.10.15

To switch back to the 2.x version use

composer self-update --rollback

Discussion (1)

pic
Editor guide
Collapse
actouf profile image
Julien actouf • Edited

Let's downgrade
composer self-update --1

  --1                        Force an update to the stable channel, but only use 1.x versions
  --2                        Force an update to the stable channel, but only use 2.x versions
Enter fullscreen mode Exit fullscreen mode