aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuillermo Ramos2021-08-24 10:05:30 +0200
committerGuillermo Ramos2021-08-24 10:07:09 +0200
commitc6f6c410baa0fe624012d46f19eeeb3dd459446a (patch)
treed6c3fdef90e79c0772e11ce35c967bb7ff6a85e8
parent12119fa837d422f55acdc904d2fbbb3bf88d527f (diff)
downloadcli-c6f6c410baa0fe624012d46f19eeeb3dd459446a.tar.gz
gromo: list
-rwxr-xr-xgromo4
1 files changed, 4 insertions, 0 deletions
diff --git a/gromo b/gromo
index e14de26..d4adff4 100755
--- a/gromo
+++ b/gromo
@@ -47,10 +47,14 @@ elif [ "$1" = "--help" ] || [ "$1" = "-h" ]; then
cmd=$(basename $0)
echo -e "Usage:
$cmd --xmobar-status \tReturn state formatted for display in xmobar
+ $cmd --list | -l \tList past gromos
$cmd --help | -h \tShow this help
$cmd [gromo] [descr] \tStart counting gromo (default gromo: "work")
"
exit 0
+elif [ "$1" = "--list" ] || [ "$1" = "-l" ]; then
+ find $DATA_DIR/ -type f -print | xargs -n 1 basename | sort -u
+ exit 0
elif [ "$#" -ge 1 ]; then
gromo="$1"
desc="$2"