TaskMonad-1.0.0: A collection of tools which can be used to access taskwarrior from xmonad.

CopyrightMax magorsch <max@magorsch.de>
LicenseBSD-style (see LICENSE)
MaintainerMax Magorsch <max@magorsch.de>
Safe HaskellNone




TaskMonad bundles a number of tools that can be used to directly interact with taskwarrior from within xmonad. Furthermore, workflows following the Getting Things Done principles are implemented.



Install with Cabal

To install TaskMonad from hackage just execute:

cabal update
cabal install TaskMonad

Afterwards import TaskMonad in your `xmonad.hs`

import TaskMonad

Install without Cabal

To install Taskmonad without using cabal just download and copy the source code into your `~.xmonad-- lib/` folder. The folder structure should afterwards look like this:

|-- lib
|   |-- Taskmonad.hs
|   |-- Taskmonad
|   |   |-- GridSelect.hs
|   |   |-- Prompt.hs
|   |   |-- ScratchPad.hs
|   |   `-- Utils.hs
|   |-- GridSelect
|   |   `-- Extras.hs
|   `-- ...
|-- xmonad.hs

Afterwards import TaskMonad in your `xmonad.hs`

import TaskMonad


To get started, add a manage hook for the taskwarrior scratchpad:

import TaskMonad

-- ...

... , manageHook = namedScratchpadManageHook taskwarriorScratchpads

After that you can bind the taskwarrior prompt to a key to get started:

... , ("M-p",     taskwarriorPrompt [(\x -> x == "processInbox", processInbox)])

You can also bind any other TaskMonad action to a key. For example:

... , ("M-S-p",   taskwarriorScratchpad)       -- Opens the taskwarrior scratchpad

... , ("M-C-p",   taskSelect "status:pending") -- Displays all pending tasks

... , ("M-C-S-p", tagSelect)                   -- Displays all tags

In general you can customize the tools ad libitum. A good way to get started is to implement custom actions for the taskwarrior prompt. Please refer to taskwarriorPrompt for further information.

Step 1: Capture

You can easily capture tasks, ideas or notes using the taskwarriorPrompt like this:

taskwarriorPrompt Source #


:: [(String -> Bool, X ())]

a list of tuples which contain a condition for an action as well as the action

-> X ()

the resulting TaskWarrior prompt

A wrapper around customPrompt that can be used to execute taskwarrior as well as custom commands.

You can specify a list of tuples which contain custom actions as well as conditions for the custom actions, like this:

taskwarriorPrompt [(\x -> x == "processInput", processInput)]

However, if none of the specified actions is true, a default action will be executed. The default action shows taskwarrior reports in a scratchpad and executes all the other commands silently.

Step 2 & 3: Clarify & Organize

You can clarify and organize your tasks using processInbox. It implements the typical Getting Things Done workflow using GridSelects:

processInbox :: X () Source #

Opens a set of gridselects used to process the inbox using the Getting Things Done workflow

Step 4: Reflect

You can implement your own custom daily- and weeklyreview routines. For example you can use togglePriority to adjust the priority of tasks during the daily- / weeklyreview like this:

togglePriority Source #


:: String

the priority that should be toggled

-> X ()

the resulting gridselect

A wrapper around togglePriorityWithConfig using the default GridSelect.Extras.GSConfig

Step 5: Engage

To decide which task to do next, you can use a collection of gridselects. You can use tagSelect, projectSelect, dueSelect to display a gridselect to filter the tasks by tag, project or due date. However you can also display all pending tasks using taskSelect like this:

taskSelect Source #


:: String

a filter to be applied, please refer to TaskWarrior Filter for further information

-> X ()

the gridselect displaying all filtered tasks

A wrapper around taskSelectWithConfig using the default GSConfig

dueSelect :: X () Source #

A wrapper around dueSelectWithConfig using the default GSConfig

tagSelect :: X () Source #

A wrapper around tagSelectWithConfig using the default GSConfig

projectSelect :: X () Source #

A wrapper around projectSelectWithConfig using the default GSConfig


The taskwarrior scratchpad is used to display taskwarrior reports that have been invoked using the taskwarrior prompt. However, you can use the scratchpad at your convenience. Just add a manage hook:

... , manageHook = namedScratchpadManageHook taskwarriorScratchpads

Afterwards you can bind a key to taskwarriorScratchpad. The Scratchpad will look like this

taskwarriorScratchpads :: [NamedScratchpad] Source #

The TaskWarrior-Scratchpad which contains a tmux session

taskwarriorScratchpad :: X () Source #

Open the TaskWarrior-ScratchPad

All Components