Extended Todo.txt Format

Yaml style todo.txt format.

+project
  +sub-prj1
  +sub-prj2

Syntax Diagram

stateDiagram-v2
  [*] --> Action
  [*] --> Priority
  Priority --> StartDate
  StartDate --> Action
  Priority --> Action
  [*] --> 'X'
  [*] --> StartDate
  'X' --> EndDate
  EndDate --> StartDate
  EndDate --> Action
  Action --> [*]

Syntax Elements

  • Project
  • Context
  • Tag
  • Metadata
  • Word
  • Date
  • Priority

Project

A project starts with + followed by at least one non-space character.

Context

A context starts with @ followed by at least one non-space character.

Tag

A tag starts with # followed by at least one non-space character.

Escape Characters

Allow escapes, including \s to mean a space. Use \n, \r and \t. Also allow unicode and hexadecimal escapes. Would be nice to allow escapes like \u{abc}. If have octal escapes use \o377 or \o{6}. I don't like the octal escapes with just digits.

Line Comments

Can start with //, ;;, --, or # followed by a space.

Support C++ line comments // a line comment
Support Clojure line comments ;; a line comment
Support Lua and SQL line comments -- a line comment
Support bash comments # a line comment

Block Comments

C/C++ style, start with /* and end with */. Also ;( and );, or ;[ and ];, or ;{ and };.

Block comments must start on their own line and end on their own line. Leading space before a block comment is fine. Trailing space after a block comment is discouraged, but OK.

/* C-style block comment
   So much to do, don't know if I'll finish.
   But at least this comment terminates! */
Support C-style block comments
;( a block comment
   with semicolon );
;[ a block comment
   with semicolon ];
;{ a block comment
   with semicolon };
Support block comments in a Clojurey style

Inline Comments

Use same syntax as block comments, but begin and end on the same line. These are really only needed when you want more inline elements after the comment. Otherwise, prefer a trailing line comment.