I have the above shell script .
#!/bin/bash
# a shell script that keeps looping until an exit code is given
nice php -q -f ./data.php -- $@
ERR=$?
exec $0 $@
I have a few doubts
- What is
$0and what is$@ - what is
ERR=$? - what does
-- $@in 5th line do - I wanted to know if can i pass data.php as a parameter. so that i have only i shell script for all kind of execution . Say, i want to run "sh ss.sh data1.php" then this should run data1.php, if run "ss ss.sh data2.php" it should run data2.php –