Custom Reports

Task allows you to customize reports. All reports are now custom reports, whereas in previous releases of task they were not mutable. This means they can be modified, renamed, or deleted.

More importantly, you can define your own. Here are the three necessary items in the .taskrc file that define a new report:

report.mine.description=Just the essentials
report.mine.columns=id,project,priority,description
report.mine.sort=priority-,project+

This defines a report, called "mine", that has four columns: id, project, priority and description. It will be sorted on two columns: by descending priority then ascending project. The description that shows up in the task command usage page is "Just the essentials". Because this report is called "mine", it can be run with the command:

% task mine

An optional filter can also be specified like this:

report.mine.filter=priority:H +bug

This adds a filter so that only tasks with priority "H" and with the "bug" tag are included in the report. This filter definition is optional.

An optional limit can also be specified, which limits the number of tasks shown in the report. If a limit is not specified, then the number of tasks is not limited.

report.mine.limit=10

Here is a list of all the possible columns that may be included in a report:

It is also possible to override the default columns names, if the following line is added to your .taskrc file:

report.mine.labels=ID,Project,Priority,Description of task

Note that there must be the same number of labels as there are columns to label, and they must appear in the same sequence.

The set of fields supported by task 1.9.0 is:

Field Example Description
id 123 Numeric task ID
uuid 301948ad-798b-489c-9a85-8008727a5351 Permanent unique identifier for tasks, as a string
project foo String
priority H Single character priority, or blank
priority_long High Single word priority, or blank
entry MM/DD/YYYY Date of task entry*
entry_time MM/DD/YYYY H:MM:SS Date and time variation*
start MM/DD/YYYY Date of task start*
start_time MM/DD/YYYY H:MM:SS Date and time variation*
end MM/DD/YYYY Date of task completion/deletion*
end_time MM/DD/YYYY H:MM:SS Date and time variation*
due MM/DD/YYYY Due date*
age 3 wks Duration since task was entered
age_compact 3wk Shorter form
active * Indicates that task is started
tags tag1 tag2 Space-separated list of words
recur monthly Recurrence duration
recurrence_indicator R Single character indicator of recurrence
tag_indicator T Single character indicator of tags
description_only Pay the rent Description only - no annotations
description Pay the rent MM/DD/YYYY by mail Description plus annotations*
wait MM/DD/YYYY Date until task reverts to pending*
  • Note: Date formatting is controlled by the 'dateformat' configuration variable.

Custom reports will show up in the task command line usage.

Also available in: HTML TXT