Snippets tagged “cli”
3 snippets use this tag.
- How to Get the Absolute Path to the Initially Run Script in PHPPHP
In this short snippet, you will find a reasonable and accurate solution to a common PHP: how to get the absolute path to the initially run script.
- Run PHP Task AsynchronouslyPHP
To run a PHP task asynchronously, you can use the pcntl_fork() function to create a new process that runs the task in parallel with the main script.
- Use different PHP version CLI executable for one commandPHP
You can use the alias command in your terminal to create a new command that runs a different version of PHP.