Files
backup/install.sh
2018-04-18 11:30:20 +02:00

13 lines
254 B
Bash
Executable File

#!/bin/bash
if ! test -x "$1"; then
echo "ERROR: call $0 path/script" 1>&2
exit 1
fi
for f in hourly daily weekly monthly; do
name=${1##*/}
echo "installing $1 to /etc/cron.$f/${name%.*}"
sudo cp $1 /etc/cron.$f/${name%.*}
done