This repository has been archived on 2026-08-11. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
dots/.local/share/task/scripts/sync-and-notify.sh
T

13 lines
294 B
Bash
Executable File

#!/usr/bin/env bash
# Redirect both stdout and stderr to notify-send as is, but set
# urgency to critical if the command fails
output="$(task rc.hooks=0 sync 2>&1)"
ret=$?
if [ $ret -ne 0 ]; then
urgency=critical
else
urgency=normal
fi
notify-send -u $urgency "Taskwarrior sync" "$output"