aboutsummaryrefslogtreecommitdiff
path: root/cmd/todo
blob: 7fb796b826fa80ae3dee806dd9d1fa59513dffb8 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/sh
# @todo - print the shared to-do list
#
# The list lives in todo.md next to this script (cmd/todo.md). Edit that
# file directly - on the server or by scp - to change it; @todo only
# reads it, and the next call reflects the edit (no restart).

file="$(dirname "$0")/todo.md"

if [ ! -f "$file" ]; then
	echo "todo: no list yet - create $file"
elif [ ! -s "$file" ]; then
	echo "todo: the list is empty"
else
	cat "$file"
fi