Created
August 7, 2018 10:48
-
-
Save tvorogme/9374e0e8b32f77b650aba37806ed6c86 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if screen -ls | grep $SCREEN_NAME | |
then | |
screen -X -S $SCREEN_NAME quit | |
else | |
echo "Session doesn't exist, going on..." | |
fi | |
screen -dmS $SCREEN_NAME | |
screen -S $SCREEN_NAME -X -X stuff 'python app.py'`echo -ne '\015'` |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Run python application in screen. Kill another screen if needed.