taskbook icon indicating copy to clipboard operation
taskbook copied to clipboard

Allow for setting due dates on tasks

Open JordanAdams opened this issue 6 years ago • 11 comments

Implements #67

Description

Adds a new due: tag to task creation allowing users to specify a due date for the task.

Other Features/Ideas

  • [x] $tb --due @1 6d for updating the due date.
  • [ ] $tb -f overdue|today|tomorrow for finding tasks based on due date.
  • [x] Apply medium priority styling to tasks due this week and and high priority styling for tomorrow.
  • [ ] Add special date/time definitions for "tomorrow" and "next-week"

Screenshots

Due Date Assignment

image

Colour-Coding

image

JordanAdams avatar Aug 08 '18 10:08 JordanAdams

Cool! What happens when a task is overdue?

ashinzekene avatar Aug 08 '18 12:08 ashinzekene

@ashinzekene Currently there's no logic to handle due dates in the past. However I would imagine the right option here is that we show something like (Due: 2 days ago) or (Due: yesterday). I'll put a fix in the add "ago" for dates in the past :)

JordanAdams avatar Aug 08 '18 12:08 JordanAdams

I feel like a due date has some idea of a priority, would it make sense to color things with a due date or to color things that are past due?

colingm avatar Aug 10 '18 20:08 colingm

@colingm Totally! I mentioned this above in the PR body :)

Apply medium priority styling to tasks due this week and and high priority styling for tomorrow.

The high priority styling should probably extend to overdue tasks too 👍

JordanAdams avatar Aug 10 '18 21:08 JordanAdams

@JordanAdams haha whoops awesome. Yeah overdue would be good. Nice work!

colingm avatar Aug 10 '18 22:08 colingm

Nice work :+1:

rjoydip-zz avatar Aug 11 '18 04:08 rjoydip-zz

May need integrating with #52, which adds an --after flag based on issue creation time. Would be nice to have similar filters based on due date also?

kalexmills avatar Aug 12 '18 15:08 kalexmills

@kalexmills The discussion around moment vs date-fns in there is interesting. I'll migrate this PR to date-fns off the back of that. The only thing we lose in doing so is .fromNow which provides the nice "in 3 days" formatting. However I've been looking at format.js as a possible alternative :)

I'll also add having a --due to the list :)

JordanAdams avatar Aug 13 '18 15:08 JordanAdams

@JordanAdams Are you talking about https://github.com/yahoo/intl-relativeformat

rjoydip-zz avatar Aug 13 '18 18:08 rjoydip-zz

@rjoydip That's the one :)

JordanAdams avatar Aug 15 '18 11:08 JordanAdams

great addition

is it possible to make a task recurring?

pannet1 avatar Aug 26 '19 04:08 pannet1