Skip to main content

This is a new website theme. Help me improve it and give your feedback (opens in a new tab).

powerline-taskwarrior

Published:

Tags:

Debian Productivity
This blog post is more than two years old. It is preserved here in the hope that it is useful to someone, but please be aware that links may be broken and that opinions expressed here may not reflect my current views. If this is a technical article, it may no longer reflect current best practice.

Basically all of my work time, both paid and volunteer, is organised by my taskwarrior database.

Sometimes it can be hard to keep focus, and in times where you find yourself forgetting what you were doing, a handy reminder can get you back on track quickly.

If you’re a powerline user then here’s something to keep you on track:

apt install python-powerline-taskwarrior python3-powerline-taskwarrior

You can configure powerline to then show you your context, active task or next task with:

[
    {
        "function": "powerline_taskwarrior.context",
        "priority": 70
    },
    {
        "function": "powerline_taskwarrior.active_task",
        "priority": 70
    },
    {
        "function": "powerline_taskwarrior.next_task",
        "priority": 70
    }
]

I’ve got the context on the left, and the active task on the right. Still playing with this to see where the optimal placement is for my workflow.

powerline-taskwarrior in action

powerline-taskwarrior in action

Note: You do need to configure some colors otherwise the segments will not work. The required colors are:

{
  "taskwarrior:context":       "information:regular",
  "taskwarrior:active_id":     { "bg": "mediumgreen", "fg": "black", "attrs": [] },
  "taskwarrior:active_desc":   { "bg": "green", "fg": "black", "attrs": [] },
  "taskwarrior:next_id":       { "bg": "brightyellow", "fg": "black", "attrs": [] },
  "taskwarrior:next_desc":     { "bg": "yellow", "fg": "black", "attrs": [] }
}