diff --git a/scripts/universal/install.sh b/scripts/universal/install.sh new file mode 100755 index 0000000..8d799b6 --- /dev/null +++ b/scripts/universal/install.sh @@ -0,0 +1,13 @@ +#!/bin/sh + +if [ "$EUID" -ne 0 ]; then + echo "Please run script as root" + exit 1 +else + if [ ! -f /bin/tidler ]; then + install -m 755 ../../src/tidler /bin/tidler + else + echo "TiDLer is already installed" + fi +fi + diff --git a/scripts/universal/update.sh b/scripts/universal/update.sh new file mode 100755 index 0000000..a923221 --- /dev/null +++ b/scripts/universal/update.sh @@ -0,0 +1,12 @@ +#!/bin/sh + +if [ "$EUID" -ne 0 ]; then + echo "Please run script as root" + exit 1 +else + if [ -f /bin/tidler ]; then + cd ../../ + git pull + install -m 755 src/tidler /bin/tidler + fi +fi