obsolete.computer

multistream/bin/djangoscript

File Type: text/x-shellscript

#!/bin/bash
[[ $1 == "update_streams" || $1 == "update_channels" ]] || exit 1

SCRIPTDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
SOURCEDIR="$SCRIPTDIR/../"

cd $SOURCEDIR
source .env || exit 1

if [[ $RUNNING_ON_DEV == "True" ]]; then
    pipenv run ./manage.py runscript $1
else
    source ../bin/activate
    python ./manage.py runscript $1
fi

Meta