mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-07-07 20:06:36 +02:00
Documentation
- Added (preliminary) example of the resultant parse tree.
This commit is contained in:
parent
66bcf26aa0
commit
60336d6f6a
1 changed files with 22 additions and 5 deletions
|
@ -64,14 +64,31 @@ from the parser, yielding a single value. As an example, the command line:
|
|||
|
||||
Is to be parsed as:
|
||||
|
||||
raw | add one due:eoy wait:due-2wks
|
||||
type | command string attr attr
|
||||
subtype | read
|
||||
attr | desc due wait
|
||||
value | eval 'eoy' eval 'due-2wks'
|
||||
index | 0 1 2 3 4
|
||||
--------+-----------------------------------------------
|
||||
raw | task add one due:eoy wait:due-2wks
|
||||
type | command string attr attr
|
||||
subtype | read
|
||||
attr | desc due wait
|
||||
value | eval 'eoy' eval 'due-2wks'
|
||||
|
||||
The eval needs of this command are:
|
||||
|
||||
'eoy' == date literal
|
||||
'due-2wks' == <dom> - <duration>
|
||||
|
||||
The parse tree should be:
|
||||
|
||||
+- add COMMAND
|
||||
+- "one" WORD
|
||||
+- attr
|
||||
| +- due ATTRIBUTE
|
||||
| +- expr
|
||||
| | + "eoy" LITERAL DATE
|
||||
+- attr
|
||||
+- wait ATTRIBUTE
|
||||
+- expr
|
||||
+= "due" DOM DATE
|
||||
+= "-" OP
|
||||
+= "2wks" LITERAL DURATION
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue