Remove listall(), list() can be used instead. - justdoit - Simpler (but with not all the features) reimplementation todo.txt CLI
(HTM) hg clone https://bitbucket.org/iamleot/justdoit
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) README
---
(DIR) changeset 49ae66e3118e2bfe225fdc16a3613b2470ec1925
(DIR) parent 648f03f0963213922a940d34a079708eb8424ddf
(HTM) Author: Leonardo Taccari <iamleot@gmail.com>
Date: Sat, 18 Aug 2018 23:44:34
Remove listall(), list() can be used instead.
Diffstat:
t.sh | 22 ++--------------------
1 files changed, 2 insertions(+), 20 deletions(-)
---
diff -r 648f03f09632 -r 49ae66e3118e t.sh
--- a/t.sh Sat Aug 18 23:42:17 2018 +0200
+++ b/t.sh Sat Aug 18 23:44:34 2018 +0200
@@ -134,25 +134,6 @@
#
-# List all entries, show the contents of todo.txt and done.txt file
-#
-listall()
-{
- tfile=$1
- dfile=$2
- search=$3
-
- if [ "${search}" ]; then
- filter() grep -F -- "${search}"
- else
- filter() cat
- fi
-
- cat "${dfile}" "${tfile}" | prettify | filter
-}
-
-
-#
# Prettify the output of a todo.txt
#
prettify()
@@ -268,7 +249,8 @@
;;
la|lsa|listall)
search=$2
- listall "${todo_file}" "${done_file}" "${search}"
+ list "${done_file}" "${search}"
+ list "${todo_file}" "${search}"
;;
*)
usage