I'm trying to do this: if a GNU screen named
worker already exists, then reattach to it, else create it by starting
if [ls /var/run/screen/S-root/ |grep -Fxq worker] then screen -r worker else cd /home/www/example/; screen -S worker python example.py fi
but it doesn't seem to work.
Is there something wrong in the syntax?