diff options
Diffstat (limited to 'todolist/parser.go')
| -rw-r--r-- | todolist/parser.go | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/todolist/parser.go b/todolist/parser.go index ca5083a..1f070c3 100644 --- a/todolist/parser.go +++ b/todolist/parser.go @@ -94,6 +94,9 @@ func (p *Parser) Due(input string, day time.Time) string { return p.saturday(day) case "sunday", "sun": return p.sunday(day) + case "last week": + n := bod(time.Now()) + return getNearestMonday(n).AddDate(0, 0, -7).Format("2006-01-02") case "next week": n := bod(time.Now()) return getNearestMonday(n).AddDate(0, 0, 7).Format("2006-01-02") |
