make run.sh cwd blind

This commit is contained in:
Benjamin Dauvergne 2013-08-15 15:11:27 +02:00
parent c41d5ab558
commit 295f0f779c
1 changed files with 6 additions and 5 deletions

11
run.sh
View File

@ -1,11 +1,12 @@
#!/bin/sh #!/bin/sh
BASE=$(dirname $0)
PROJECT=docbow PROJECT=docbow
CTL=${PROJECT}-ctl CTL=$BASE/${PROJECT}-ctl
VENV=${PROJECT}-venv VENV=$BASE/${PROJECT}-venv
if [ ! -d $VENV ]; then if [ ! -d $VENV ]; then
./start.sh $BASE/start.sh
else else
. ./$VENV/bin/activate . $VENV/bin/activate
./$CTL "${@:-runserver}" $CTL "${@:-runserver}"
fi fi