This is random shell. It's probably useless to you, but it demonstrates how you can make a bash-like cli in php (which is a really wierd thing to want to do...)
If anyone ever wants to try this out, you need to be running the console or some xterm derivative.
Also, I used the php7 engine, but it should be php5 compatible
To run it issue
$ chmod +x main
$./main