Old WP-CLI version 0.15.0 when running vagrant ssh

Bedrock is up and running and I am trying to use WP-CLI on the virtual machine. I installed a few plugins and ran wp plugin activate --all with no success. These are the exact commands:

vagrant ssh
cd ../../srv/www/example.com/current
wp plugin activate --all

I discovered the wp plugin activate --all command was added in WP-CLI version 0.18.0 but the version running on the virtual machine is only 0.15.0. I then tried updating, but I can’t run wp cli update because the update command wasn’t added until version 0.18.0. So I have a few questions:

  1. Is this the recommended way to use WP-CLI with Bedrock (via ssh on the virtual machine or should I be running WP-CLI from the host OS)?
  2. If this is the recommended method, why is my version of WP-CLI so outdated? I notice if I run wp cli version from OS X terminal it shows 0.18.0 but inside the virtual machine it is only 0.15.0.
  3. Since the update command doesn’t work prior to 0.18.0, how do I update WP-CLI on the vm? I’ve read every doc on the WP-CLI website and I’m stumped.
  4. Should I have to update WP-CLI myself every time I use bedrock-ansible or should it be installing the most recent version?

Thanks.

Relevant:

Thanks. Is there any way to update WP-CLI manually in the meantime? The only way I know how is wp cli update which isn’t available until 0.18.0.

Have you tried sshing into the box and following the install/upgrade instructions?

@swalkinshaw need to upgrade wp-cli on the box and get the vagrant box hosted somewhere other than my box lol :slight_smile: