Download this file

update.sh    22 lines (17 with data), 541 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/bin/bash
if [ -z "$VIRTUAL_ENV" ]; then
echo "You need to activate your virtualenv first!";
exit;
fi
echo 'Getting latest code with `git pull` ...'
git pull
echo 'Updating python packages with `pip install -r requirements.txt` ...'
pip install -r requirements.txt
if [ "$?" -gt 0 ]; then
echo
echo
echo 'Command `pip install -r requirements.txt` failed. Sometimes this is a random download error. If so, just try again.'
exit;
fi
./rebuild.bash
echo 'If you have taskd or the web server running, you should restart them now.'