You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
338 B

#!/bin/sh
export FLASK_APP=server.py
loc=false
noh=false
while getopts "ln" opt; do
case $opt in
l) loc=true ;;
n) noh=true ;;
\?) echo "Invalid argument" ;;
esac
done
if $aflag; then
if $noh; then
nohup flask run&
else
flask run
fi
else
if $noh; then
nohup flask run --host=0.0.0.0&
else
flask run -host=0.0.0.0
fi
fi