From 51c95762d47abf6b8801b99ab05d44281ffdc446 Mon Sep 17 00:00:00 2001 From: Gardouille Date: Mon, 23 Mar 2020 08:16:19 +0100 Subject: [PATCH] Add timew function for last month and week --- zshrc | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) diff --git a/zshrc b/zshrc index 0dc54cf..dfbdfc2 100644 --- a/zshrc +++ b/zshrc @@ -365,6 +365,15 @@ function taweek() { fi } ## }}} +## Display tasks of last week {{{ +function talastweek() { + if [ "${#}" -eq 0 ]; then + timew summary :lastweek :ids + else + timew summary :lastweek :ids "${*}" + fi +} +## }}} ## Display tasks of this month {{{ function tamonth() { if [ "${#}" -eq 0 ]; then @@ -374,6 +383,15 @@ function tamonth() { fi } ## }}} +## Display tasks of last month {{{ +function talastmonth() { + if [ "${#}" -eq 0 ]; then + timew summary :lastmonth :ids + else + timew summary :lastmonth :ids "${*}" + fi +} +## }}} ## Display tasks of this year {{{ function tayear() { if [ "${#}" -eq 0 ]; then @@ -383,6 +401,15 @@ function tayear() { fi } ## }}} +## Display tasks of last year {{{ +function talastyear() { + if [ "${#}" -eq 0 ]; then + timew summary :lastyear :ids + else + timew summary :lastyear :ids "${*}" + fi +} +## }}} ## Completion zstyle ':completion:*:*:task:*' verbose yes