Robo not 'recognized or external command' on Windows10? (Upgrade SuiteCRM version)

Hi,

I would like to upgrade from SuiteCRM 7.11 to 7.11.8 using the silent upgrade via the robo command to test if our customization all survive an update to later automate the update process in a batch job.

I am on Windows, which might explain most of my problems, I guess. I followed the instructions here: https://docs.suitecrm.com/admin/installation-guide/upgrading/ but Windows does not seem to like the ‘robo’ file that it is supposed to use.

I am on Windows 10 but executing the CLI upgrade command gives me every time “’.\vendor\bin\robo’ is not recognized as an internal or external command,
operable program or batch file.”
Likewise, ‘robo list’ gives the same error.

I assume something is missing in my local installation? Maybe an environmental variable that has to be set or so? (I am sure the interactive Wizard will work, but we would want to go the CLI way)

Thanks for any pointers~
Best,

Robo lives in vendor/bin/robo

There are two ways for it to get there:

  • if you use a full package or an upgrade package, we include all the contents of the vendor dir, even if it is not in our repo - it is an extra step we do when creating the packages.

  • but if you grab our code directly from the repo, with Git or by downloading the zip, then you need to have “composer” installed in your machine and run

composer install --no-dev

I do have a folder …/vendor/bin with robo in it, it has only 1KB in size and its content is


../consolidation/robo/robo

This file points to a file that is then a php file which looks like robo but neither is a script or binary file that is executable form command line? Do I now still have to install this composer?

That is a link to a different directory:


10.0.0.200 | root /var/www/html (master) $ ll vendor/bin/robo
lrwxrwxrwx 1 www-data www-data 26 Mar 19  2019 vendor/bin/robo -> ../consolidation/robo/robo*

Then if you list the other directory, you get


10.0.0.200 | root /var/www/html (master) $ ll vendor/consolidation/robo/
total 252
drwxr-sr-x  6 www-data www-data   4096 Sep 28 12:25 ./
drwxrwsr-x  8 www-data www-data   4096 Jun 11 14:35 ../
-rw-r--r--  1 www-data www-data  18626 Jul 29 16:40 CHANGELOG.md
-rw-r--r--  1 www-data www-data    381 Jul 29 16:40 codeception.yml
-rw-r--r--  1 www-data www-data   3472 Jul 29 16:40 composer.json
-rw-r--r--  1 www-data www-data 148285 Jul 29 16:40 composer.lock
-rw-r--r--  1 www-data www-data    920 Jul 29 16:40 CONTRIBUTING.md
drwxr-sr-x  3 www-data www-data   4096 Jul 29 16:40 data/
-rw-r--r--  1 www-data www-data    322 Jul 29 16:40 dependencies.yml
-rw-r--r--  1 www-data www-data    254 Jul 29 16:40 .editorconfig
-rw-r--r--  1 www-data www-data   2192 Jul 29 16:40 LICENSE
-rw-r--r--  1 www-data www-data   1037 Jul 29 16:40 phpunit.xml
-rw-r--r--  1 www-data www-data   5947 Jul 29 16:40 README.md
-rwxr-xr-x  1 www-data www-data   1630 Jul 29 16:40 robo*
-rw-r--r--  1 www-data www-data  15830 Jul 29 16:40 RoboFile.php
-rw-r--r--  1 www-data www-data    106 Jul 29 16:40 robo.yml
drwxr-sr-x  4 www-data www-data   4096 Jul 29 16:40 .scenarios.lock/
drwxr-sr-x  3 www-data www-data   4096 Jul 29 16:40 scripts/
drwxr-sr-x 11 www-data www-data   4096 Jul 29 16:40 src/
10.0.0.200 | root /var/www/html (master) $

If you don’t have that, you need to get it either from the upgrade package (not the Zip from Github), or from installing and running composer (which I recommend).

Thanks.

I figured out how to start the update.

When typing explicitly ‘php consolidation/robo/robo …’ it works but just plain ‘robo’ doesn’t work and htis redirect form vendors/bin/ isnt working on my Windows machine.

P.S. you need php to be on your classpath for this to work.

Not exactly the way it should work but the upgrade gets started this way and also terminates successfully.

1 Like

HI @karada @pgr

Facing the similar issue with respect to robo …

Trying to use robo for automated tests, ie starting with automated tests for our CRM.

I am trying the below step in this link https://docs.suitecrm.com/developer/automatedtesting/

I get below error when i tried in git bash

Below is the error when i tried in command prompt

I can see the recent comment from @karada that he was able to run with ‘php consolidation/robo/robo …’

when I try as above i get below error

also i can confirm that robo has installed fine… as i can get the list something similar to @pgr suggestions in this post,Please find the attached screenshot

Kindly guide , please point out if i m doing wrong.

I m trying this in windows, and version of suitecrm is 7.11.10

Thanks for your time.

Regards,
Sravani

The path you use in the command depends on the path where you are at the moment, when giving the command.

So first go to the SuiteCRM root, for example. In your case, E:\Sravani\xampp\htdocs\crm_staging

And from there you should be able to do this in git bash

php vendor/consolidation/robo/robo list

Or this in Windows Command Prompt:

php -f “E:\Sravani\xampp\htdocs\crm_staging\vendor\consolidation\robo\robo” list

2 Likes