diff options
author | ivanp7 | 2022-11-12 21:32:57 +0300 |
---|---|---|
committer | ivanp7 | 2022-11-18 15:50:10 +0300 |
commit | 52d8d1286ed0fa97d9151ba91790abf180ac27de (patch) | |
tree | fd2053d02e09098f481c3d1792f83d73b3b85932 /usage-logging.install | |
download | aur-usage-logging.tar.gz |
initial commit
Diffstat (limited to 'usage-logging.install')
-rw-r--r-- | usage-logging.install | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/usage-logging.install b/usage-logging.install new file mode 100644 index 000000000000..658c93ddd696 --- /dev/null +++ b/usage-logging.install @@ -0,0 +1,14 @@ +CRON_TASK="* * * * * /usr/bin/usage-logging/another-minute.sh" + +post_install () +{ + echo "Adding cron task..." + crontab -l | { cat; echo "$CRON_TASK"; } | crontab - +} + +pre_remove () +{ + echo "Removing cron task..." + crontab -l | grep -Fxv "$CRON_TASK" | crontab - +} + |