mirror of
https://github.com/GothenburgBitFactory/timewarrior.git
synced 2025-07-07 20:06:39 +02:00
dom: Added 'dom.active.duration' support
This commit is contained in:
parent
e543174c19
commit
72a37db559
1 changed files with 9 additions and 0 deletions
|
@ -27,6 +27,7 @@
|
|||
#include <cmake.h>
|
||||
#include <timew.h>
|
||||
#include <Pig.h>
|
||||
#include <Duration.h>
|
||||
#include <format.h>
|
||||
#include <vector>
|
||||
#include <iostream>
|
||||
|
@ -59,6 +60,14 @@ bool domGet (
|
|||
return true;
|
||||
}
|
||||
|
||||
// dom.active.duration
|
||||
if (pig.skipLiteral (".duration") &&
|
||||
latest.range.is_open ())
|
||||
{
|
||||
value = Duration (latest.range.total ()).formatISO ();
|
||||
return true;
|
||||
}
|
||||
|
||||
// dom.active.tag.count
|
||||
if (pig.skipLiteral (".tag.count"))
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue