blob: 389b4b48331736532f1d3a0cc94dcf0ce55a7824 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
#!/bin/bash
PRG="$0"
while [ -h "$PRG" ]; do
ls=`ls -ld "$PRG"`
link=`expr "$ls" : '.*-> \(.*\)$'`
if expr "$link" : '/.*' > /dev/null; then
PRG="$link"
else
PRG=`dirname "$PRG"`/"$link"
fi
done
SCRIPT_HOME=`dirname "$PRG"`
$SCRIPT_HOME/update
if [ "$?" -eq 1 ]; then
echo "Uploading updated TWS"
burp -c office $SCRIPT_HOME/*.gz
echo "Updating Git"
cd $SCRIPT_HOME
git commit -a -m "Commit from upload script due to new version"
git push
fi
|