aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorSebastiano Tronto <sebastiano.tronto@gmail.com>2021-12-22 09:10:09 +0100
committerSebastiano Tronto <sebastiano.tronto@gmail.com>2021-12-22 09:10:09 +0100
commitd506146c55ffa28ed8f5ba2d7ebd496e60e6a8d4 (patch)
tree892cbe9b74dd914bc5b7e6148a4cfe115eaf4f76 /scripts
parent9902b66c098b51ac91785eb5d929a73b981ce08c (diff)
downloadsdep-d506146c55ffa28ed8f5ba2d7ebd496e60e6a8d4.tar.gz
sdep-d506146c55ffa28ed8f5ba2d7ebd496e60e6a8d4.zip
added a script to check past events and notify
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/sdep-checkpast21
1 files changed, 21 insertions, 0 deletions
diff --git a/scripts/sdep-checkpast b/scripts/sdep-checkpast
new file mode 100755
index 0000000..fa8164d
--- /dev/null
+++ b/scripts/sdep-checkpast
@@ -0,0 +1,21 @@
1#!/bin/sh
2
3# Run this at boot to receive a notification about past events that you might
4# have missed
5#
6# The events are read from the following files in SDEPDATA folder:
7# once: events that only happen once; full date needs to be specified
8# daily: events that happen every day; only specify the time in HH:MM format
9# weekly: only specify Weekday + time
10# monthly: only specify day of the month + time
11
12# Requires: notify-send.
13
14notify="notify-send -t 3600000"
15
16sdep-list past | \
17while read text; do
18 date=$(echo "$text" | sed 's/\t.*//')
19 event=$(echo "$text" | sed 's/.*\t//')
20 $notify "$date" "$event"
21done

Generated with cgit - Back to sebastiano.tronto.net