PHP code example of veewee / composer-run-parallel

1. Go to this page and download the library: Download veewee/composer-run-parallel library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

veewee / composer-run-parallel example snippets

json
{
  "scripts": {
    "php1": "@php -r 'sleep(3); echo \"1\";'",
    "php2": "@php -r 'echo \"2\";'"
  }
}
json
{
  "scripts": {
    "php1": "@php -r 'sleep(3); echo \"1\";'",
    "php2": "@php -r 'echo \"2\";'",
    "php1And2": "@parallel php1 php2"
  }
}
json
{
  "scripts": {
    "php1": "@php -r 'sleep(3); echo \"1\";'",
    "phpfail": "@php -r 'throw new Exception(\"FAIL\");'"
  }
}