From 97d9d7bc44a8ab7ead6402ec00e5b13c8949d99d Mon Sep 17 00:00:00 2001 From: Alex Epstein Date: Sat, 15 Jul 2017 20:40:39 -0400 Subject: [PATCH] Adding usage to todo tool --- todo/todo | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/todo/todo b/todo/todo index 7ea1948..d87fa88 100755 --- a/todo/todo +++ b/todo/todo @@ -125,6 +125,25 @@ getTasks() fi } +usage() +{ + echo "Todo" + echo "Description: A simplistic commandline todo list." + echo "Usage: todo [flags] or todo [flags] [arguments]" + echo " -c Clear all the current tasks" + echo " -r Remove the following task number" + echo " -g Get the current tasks" + echo " -a Add the following task" + echo " -u Update Bash-Snippet Tools" + echo " -h Show the help" + echo " -v Get the tool version" + echo "Examples:" + echo " todo -a My very first task" + echo " todo -r 1" + echo " todo -g" + echo " todo -c" +} + clearAllTasks() { rm -f ~/.todo/list.txt || return 1