Ubuntu Manpages

task

A command line todo manager.

task <filter> <command> [ <mods> | <args> ]
task --version

Taskwarrior is a command line todo list manager. It maintains a list of tasks that you want to do, allowing you to add/remove, and otherwise manipulate them. Taskwarrior has a rich set of subcommands that allow you to do various things with it.

At the core, taskwarrior is a list processing program. You add text and additional related parameters and redisplay the information in a nice way. It turns into a todo list program when you add due dates and recurrence. It turns into an organized todo list program when you add priorities, tags (one word descriptors), project groups, etc.

The <filter> consists of zero or more search criteria that select tasks. For example, to list all pending tasks belonging to the 'Home' project:


task project:Home list

You can specify multiple filter terms, each of which further restricts the result:


task project:Home +weekend garden list

This example applies three filters: the 'Home' project, the 'weekend' tag, and the description or annotations must contain the character sequence 'garden'. In this example, 'garden' is translated internally to:


description.contains:garden

as a convenient shortcut. The 'contains' here is an attribute modifier, which is used to exert more control over the filter than simply absence or presence. See the section 'ATTRIBUTE MODIFIERS' below for a complete list of modifiers.

Note that a filter may have zero terms, which means that all tasks apply to the command. This can be dangerous, and this special case is confirmed, and cannot be overridden. For example, this command:


task modify +work
This command has no filter, and will modify all tasks. Are you sure? (yes/no)

will add the 'work' tag to all tasks, but only after confirmation.

More filter examples:


task <command> <mods>
task 28 <command> <mods>
task +weekend <command> <mods>
task project:Home due.before:today <command> <mods>
task ebeeab00-ccf8-464b-8b58-f7f2d606edfb <command> <mods>

By default filter elements are combined with an implicit 'and' operator, but 'or' and 'xor' may also be used, provided parentheses are included:


task '( /[Cc]at|[Dd]og/ or /[0-9]+/ )' <command> <mods>

The parentheses isolate the logical term from any default command filter or implicit report filter which would be combined with an implicit 'and'.

A filter may target specific tasks using ID or UUID numbers. To specify multiple tasks use one of these forms (comma or space-separated list of ID numbers, UUID numbers or ID ranges):


task 1,2,3 delete
task 1-3 info
task 1,2-5,19 modify pri:H
task 4-7 ebeeab00-ccf8-464b-8b58-f7f2d606edfb info

The <mods> consist of zero or more changes to apply to the selected tasks, such as:


task <filter> <command> project:Home
task <filter> <command> +weekend +garden due:tomorrow
task <filter> <command> Description/annotation text
task <filter> <command> /from/to/

Taskwarrior supports different kinds of commands. There are read commands, write commands, miscellaneous commands and script helper commands. Read commands do not allow modification of tasks. Write commands can alter almost any aspect of a task. Script helper commands are provided to help you write add-on scripts, for example, shell completion (only minimal output is generated, as with verbose=nothing).

Reports are read subcommands. There are several reports currently predefined in taskwarrior. The output and sort behavior of these reports can be configured in the configuration file. See also the man page taskrc(5). There are also other read subcommands that are not reports.

This is the only conventional command line argument that Taskwarrior supports, and is intended for add-on scripts to verify the version number of an installed Taskwarrior without invoking the mechanisms that create default files.

With no command specified, the default command is run, and the filter applied.

Shows all tasks matching the filter that are started but not completed.

Shows all tasks matching the filter, including parents of recurring tasks.

Shows all tasks matching the filter, that are currently blocked by other tasks.

Shows all tasks matching the filter, that block other tasks.

Shows a graphical burndown chart, by day. Note that 'burndown' is an alias to the 'burndown.daily' report.

Shows a graphical burndown chart, by week.

Shows a graphical burndown chart, by month.

Shows a monthly calendar with due tasks marked. Shows one horizontal line of months. If the 'y' argument is provided, will show at least one complete year. If a year is provided, such as '2013', then that full year is shown. If both a month and a year are specified ('6 2013') then the months displayed begin at the specified month and year. If the 'due' argument is provided, will show the starting month of the earliest due task.

Displays all possible colors, a named sample, or a legend containing all currently defined colors.

Displays all supported columns and formatting styles. Useful when creating custom reports. If a substring is provided, only matching column names are shown.

Shows all tasks matching the filter that are completed.

Displays only a count of tasks matching the filter.

Exports all tasks in the JSON format. Redirect the output to a file, if you wish to save it, or pipe it to another command or script to convert it to another format. The standard task release comes with a few example scripts, such as export-yaml.pl.

Shows a graphical report of task status by year.

Shows a graphical report of task status by month. Note that 'ghistory' is an alias to 'ghistory.monthly'.

Shows the long usage text.

Shows a report of task history by year.

Shows a report of task history by month. Note that 'history' is an alias to 'history.monthly'.

Applies the filter then extracts only the task IDs and presents them as a range, for example: 1-4,12. This is useful as input to a task command, to achieve this:

task $(task project:Home ids) modify priority:H

This example first gets the IDs for the project:Home filter, then sets the priority to H for each of those tasks. This can also be achieved directly:


task project:Home modify priority:H

This command is mainly of use to external scripts.

Applies the filter on all tasks (even deleted and completed tasks) then extracts only the task UUIDs and presents them as a comma-separated list. This is useful as input to a task command, to achieve this:

task $(task project:Home status:completed uuids) modify status:pending

This example first gets the UUIDs for the project:Home and status:completed filters, then makes each of those tasks pending again.

This command is mainly of use to external scripts.

Shows a list of UDAs that are defined, including their name, type, label and allowed values. Also shows UDA usage and any orphan UDAs.

Shows all data and metadata for the specified tasks. This is the only means of displaying all aspects of a given task, including the change history.

Provides a standard listing of tasks matching the filter.

Provides the most detailed listing of tasks matching the filter.

Provides a short listing of tasks matching the filter.

Provides a minimal listing of tasks matching the filter.

Shows the newest tasks matching the filter.

Shows a page of the most urgent tasks, sorted by urgency, which is a calculated value.

Shows a page of the most urgent ready tasks, sorted by urgency. A ready task is one that is either unscheduled, or has a scheduled date that is past and has no wait date.

Shows the oldest tasks matching the filter.

Shows all incomplete tasks matching the filter that are beyond their due date.

Lists all project names that are currently used by pending tasks, and the number of tasks for each.

Shows all recurring tasks matching the filter.

Shows all tasks that are not currently blocked by other tasks, matching the filter.

Shows all waiting tasks matching the filter.

Adds a new pending task to the task list.

Adds an annotation to an existing task.

Appends description text to an existing task.

Deletes the specified task from task list.

Deletes an annotation for the specified task. If the provided description matches an annotation exactly, the corresponding annotation is deleted. If the provided description matches annotations partly, the first partly matched annotation is deleted.

Marks the specified task as done.

Duplicates the specified task and allows modifications.

Launches a text editor to let you modify all aspects of a task directly. In general, this is not the recommended method of modifying tasks, but is provided for exceptional circumstances. Use carefully.

Imports tasks in the JSON format. The standard task release comes with a few example scripts, such as import-yaml.pl.

Adds a new task that is already completed, to the task list.

Merges two task databases by comparing the modifications that are stored in the undo.data files. The location of the second undo.data file must be passed on as argument. URL may have the following syntaxes:

ssh://[user@]host.xz[:port]/path/to/.task/

rsync://[user@]host.xz[:port]/path/to/.task/

[user@]host.xz:path/to/.task/

/path/to/local/.task/

You can set aliases for frequently used URLs in the .taskrc. Further documentation can be found in the task-sync(5) man page.

Modifies the existing task with provided information.

Prepends description text to an existing task.

Overwrites the task database with those files found at the URL. (See 'merge' command for valid URL syntax.)

Pushes the task database to a remote location for distributing the changes made by the merge command. (See 'merge' command for valid URL syntax.)

Marks the specified tasks as started.

Removes the start time from the specified task.

Miscellaneous subcommands either accept no command line arguments, or accept non-standard arguments.

Add, modify and remove settings directly in the taskwarrior configuration. This command either modifies the 'name' setting with a new value of 'value', or adds a new entry that is equivalent to 'name=value':


task config name value

This command sets a blank value. This has the effect of suppressing any default value:


task config name ''

Finally, this command removes any 'name=...' entry from the .taskrc file:


task config name

Shows diagnostic information, of the kind needed when reporting a problem. When you report a bug, it is likely that the platform, version, and environment are important. Running this command generates a summary of similar information that should accompany a bug report.

It includes compiler, library and software information. It does not include any personal information, other than the location and size of your task data files.

This command also performs a diagnostic scan of your data files looking for common problems, such as duplicate UUIDs.

Executes the specified command. Not useful by itself, but when used in conjunction with aliases and extensions can provide seamless integration.

Displays the Taskwarrior logo.

Lists all supported reports. This includes the built-in reports, and any custom reports you have defined.

Launches an interactive shell with all the task commands available.

Shows all the current settings. If a substring is specified just the settings containing that substring will be displayed.

Shows statistics of the tasks defined by the filter.

Shows a report of aggregated task status by project.

Show a list of all tags used. Any special tags used are highlighted. Note that virtual tags are not listed - they don't really exist, and are just a convenient notation for other task metadata.

Shows a weekly report of tasks completed and started.

Reverts the most recent action. Obeys the confirmation setting.

Shows the taskwarrior version number.

Generates a list of all aliases, for autocompletion purposes.

Displays only a list of supported columns.

Generates a list of all commands, for autocompletion purposes.

Lists all supported configuration variables, for completion purposes.

Shows only the IDs of matching tasks, in the form of a list.

Shows the combined defaults and overrides of the configuration settings, for use by third-party applications.

Shows only the UUIDs of matching tasks among all tasks (even deleted and completed tasks), in the form of a list.

Shows only defined UDA names, in the form of a list.

Shows only a list of all project names used.

Shows only a list of all tags used, for autocompletion purposes.

Displays the urgency measure of a task.

Shows only the taskwarrior version number.

Generates a list of all commands, for zsh autocompletion purposes.

Shows the IDs and descriptions of matching tasks.

Shows the UUIDs and descriptions of matching tasks.

Tasks can be specified uniquely by IDs, which are simply the indexes of the tasks in the data file. The ID of a task may therefore change, but only when a command is run that displays IDs. When modifying tasks, it is safe to rely on the last displayed ID. Always run a report to check you have the right ID for a task. IDs can be given to task as a sequence, for example,
task 1,4-10,19 delete

+tag|-tag
Tags are arbitrary words associated with a task. Use + to add a tag and - to remove a tag from a task. A task can have any quantity of tags.

Certain tags (called 'special tags'), can be used to affect the way tasks are treated. For example, if a task has the special tag 'nocolor', then it is exempt from all color rules. The supported special tags are:


+nocolor Disable color rules processing for this task
+nonag Completion of this task suppresses all nag messages
+nocal This task will not appear on the calendar
+next Elevates task so it appears on 'next' report

There are also virtual tags, which represent task metadata in tag form. These tags do not exist, but can be used to filter tasks. The supported virtual tags are:


BLOCKED Matches if the task is blocked
UNBLOCKED Matches if the task is not blocked
BLOCKING Matches if the task is blocking
DUE Matches if the task is due
DUETODAY Matches if the task is due today
TODAY Matches if the task is due today
OVERDUE Matches if the task is overdue
ACTIVE Matches if the task is started
SCHEDULED Matches if the task is scheduled
CHILD Matches if the task has a parent
UNTIL Matches if the task expires
WAITING Matches if the task is waiting
ANNOTATED Matches if the task has annotations

You can use +BLOCKED to filter blocked tasks, or -BLOCKED for unblocked tasks. Similarly, -BLOCKED is equivalent to +UNBLOCKED.

Specifies the project to which a task is related to.

Specifies High, Medium, Low and no priority for a task.

Specifies the due-date of a task.

Specifies the frequency of a recurrence of a task.

Specifies the date after which a task can be accomplished.

Specifies the expiration date of a task, after which it will be deleted.

Specifies the desired number of tasks a report should show, if a positive integer is given. The value 'page' may also be used, and will limit the report output to as many lines of text as will fit on screen. This defaults to 25 lines.

Date until task becomes pending.

Declares this task to be dependent on id1 and id2. This means that the tasks id1 and id2 should be completed before this task. Consequently, this task will then show up on the 'blocked' report. It accepts a comma-separated list of ID numbers, UUID numbers and ID ranges. When prefixing any element of this list by '-', the specified tasks are removed from the dependency list.

For report purposes, specifies the date that a task was created.

Attribute modifiers improve filters. Supported modifiers are:

before (synonyms under, below)
after (synonyms over, above)
none
any
is (synonym equals)
isnt (synonym not)
has (synonym contains)
hasnt
startswith (synonym left)
endswith (synonym right)
word
noword

For example:

task due.before:eom priority.not:L list

The before modifier is used to compare values, preserving semantics, so project.before:B list all projects that begin with 'A'. Priority 'L' is before 'M', and due:2011-01-01 is before due:2011-01-02. The synonyms 'under' and 'below' are included to allow filters that read more naturally.

The after modifier is the inverse of the before modifier.

The none modifier requires that the attribute does not have a value. For example:


task priority: list
task priority.none: list

are equivalent, and list tasks that do not have a priority.

The any modifier requires that the attribute has a value, but any value will suffice.

The is modifier requires an exact match with the value.

The isnt modifier is the inverse of the is modifier.

The has modifier is used to search for a substring, such as:


task description.has:foo list
task foo list

These are equivalent and will return any task that has 'foo' in the description or annotations.

The hasnt modifier is the inverse of the has modifier.

The startswith modifier matches against the left, or beginning of an attribute, such that:


task project.startswith:H list
task project:H list

are equivalent and will match any project starting with 'H'. Matching all projects not starting with 'H' is done with:


task project.not:H list

The endswith modifier matches against the right, or end of an attribute.

The word modifier requires that the attribute contain the whole word specified, such that this:


task description.word:bar list

Will match the description 'foo bar baz' but does not match 'dog food'.

The noword modifier is the inverse of the word modifier.

You can use the following operators in filter expressions:


and or xor Logical operators
< <= = != >= > Relational operators
( ) Precedence

For example:


task due.before:eom priority.not:L list
task '( due < eom or priority != L )' list

Note that the parentheses are required when using a logical operator other than the 'and' operator. The reason is that some reports contain filters that must be combined with the command line. Consider this example:


task project:Home or project:Garden list

While this looks correct, it is not. The 'list' report contains a filter of:


task show report.list.filter


Config Variable Value
----------------- --------------
report.list.filter status:pending

Which means the example is really:


task status:pending project:Home or project:Garden list

The implied 'and' operator makes it:


task status:pending and project:Home or project:Garden list

This is a precedence error - the 'and' and 'or' need to be grouped using parentheses, like this:


task status:pending and ( project:Home or project:Garden ) list

The original example therefore must be entered as:


task '( project:Home or project:Garden )' list

This includes quotes to escape the parentheses, so that the shell doesn't interpret them and hide them from taskwarrior.

There is redundancy between operators, attribute modifiers and other syntactic sugar. For example, the following are all equivalent:


task foo list
task /foo/ list
task description.contains:foo list
task description.has:foo list
task 'description ~ foo' list

Taskwarrior reads dates from the command line and displays dates in the reports. The expected and desired date format is determined by the configuration variable dateformat

task ... due:7/14/2008

task ... due:20130314T223000Z

task ... due:now
task ... due:today
task ... due:yesterday
task ... due:tomorrow

task ... due:23rd
task ... due:3wks
task ... due:1day
task ... due:9hrs


task ... due:sow
task ... due:soww
task ... due:socw
task ... due:som
task ... due:soq
task ... due:soy


task ... due:eow
task ... due:eoww
task ... due:eocw
task ... due:eom
task ... due:eoq
task ... due:eoy


task ... wait:later
task ... wait:someday

This sets the wait date to 1/18/2038.

task ... due:fri

Recurrence periods. Taskwarrior supports several ways of specifying the frequency of recurring tasks.

Every day or a number of days.

Mondays, Tuesdays, Wednesdays, Thursdays, Fridays and skipping weekend days.

Every week or a number of weeks.

Every two weeks.

Every month.

Every three months, a quarter, or a number of quarters.

Every six months.

Every year or a number of years.

Every two years.

All taskwarrior commands may be abbreviated as long as a unique prefix is used, for example:

$ task li

is an unambiguous abbreviation for

$ task list

but

$ task l

could be list, ls or long.

Note that you can restrict the minimum abbreviation size using the configuration setting:

abbreviation.minimum=3

Some task descriptions need to be escaped because of the shell and the special meaning of some characters to the shell. This can be done either by adding quotes to the description or escaping the special character:

$ task add "quoted ' quote"
$ task add escaped \' quote

The argument -- (a double dash) tells taskwarrior to treat all other args as description:

$ task add -- project:Home needs scheduling

In other situations, the shell sees spaces and breaks up arguments. For example, this command:

$ task 123 modify /from this/to that/

is broken up into several arguments, which is corrected with quotes:

$ task 123 modify "/from this/to that/"

It is sometimes necessary to force the shell to pass quotes to Taskwarrior intact, so you can use:

$ task add project:\'Three Word Project\' description

Taskwarrior stores its configuration in a file in the user's home directory: ~/.taskrc. The default configuration file can be overridden with:

Specifies an alternate configuration file.

The environment variable overrides the default and the command line specification of the .taskrc file.

task rc.<name>=<value> ... Specifies individual configuration file overrides.

The environment variable overrides the default, the command line, and the 'data.location' configuration setting of the task data directory.

For examples please see the task tutorial man page at

man task-tutorial

or the online documentation starting at

<http://taskwarrior.org/projects/taskwarrior/wiki>

Note that the online documentation is more detailed and more current than this man page.

~/.taskrc
User configuration file - see also taskrc(5). Note that this can be overridden on the command line or by the TASKRC environment variable.

~/.task
The default directory where task stores its data files. The location can be configured in the configuration variable 'data.location', or overridden with the TASKDATA environment variable..

~/.task/pending.data
The file that contains the tasks that are not yet done.

~/.task/completed.data
The file that contains the completed ("done") tasks.

~/.task/undo.data
The file that contains information needed by the "undo" and "merge" commands.

Copyright (C) 2006 - 2013 P. Beckingham, F. Hernandez.

Taskwarrior is distributed under the MIT license. See http://www.opensource.org/licenses/mit-license.php for more information.

taskrc(5), task-tutorial(5), task-faq(5), task-color(5), task-sync(5)

For more information regarding taskwarrior, see the following:

<http://taskwarrior.org>

<git://tasktools.org/task.git/>

<support@taskwarrior.org>

<http://taskwarrior.org>