diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2018-05-23 08:11:58 -0300 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2018-05-23 08:11:58 -0300 |
commit | ac48b0fa468c47ff5ac878191f2de37a9b76a49e (patch) | |
tree | a1ebc4fdf055cf8fe5661f0ddf58fa3ec3e45f35 /todo | |
parent | 03d3b1cc6f45049efc063dc7cfda35567c168713 (diff) | |
download | scripts-ac48b0fa468c47ff5ac878191f2de37a9b76a49e.tar.gz scripts-ac48b0fa468c47ff5ac878191f2de37a9b76a49e.tar.bz2 |
De-uglify a bit todo and status outputs
Diffstat (limited to 'todo')
-rwxr-xr-x | todo | 23 |
1 files changed, 14 insertions, 9 deletions
@@ -40,21 +40,26 @@ function todo_list { # User's Taskwarrior if which task &> /dev/null; then - echo "taskwarrior:" - echo "" - task list 2> /dev/null - echo "" + if [ "`task status:pending count`" != "0" ]; then + echo "taskwarrior:" + #echo "" + task list 2> /dev/null + echo "" + fi fi + # Taskwarrior data from projects + SILENT=true tasks +$status list + echo "" + # User's Timewarrior if which timew &> /dev/null; then - timew | grep -v "^There is no active time tracking." - echo "" + if ! timew | grep -q "^There is no active time tracking."; then + timew + echo "" + fi fi - # Timewarrior data from projects - SILENT=true tasks +$status list - todo_find | while read todo; do if [ "$todo" != "$NAME" ]; then if [ ! -z "$status" ] && ! grep -q "\($status\)" $todo; then |