Will this output to browsers? If so, perhaps wrap `index.php` with something like `cli.php` which simply includes it?