- Implemented pre-completed, post-completed events.
- Added debug info for event triggers.
- Removed support for pre-file-unlock, post-file-unlock, as they are
called from TDB::~TDB in Context::~Context, which is after Hooks::~Hooks,
which means segfault.
- Implemented Path::operator (std::string) const, to provide an
automatic cast to std::string for any Path, File or Directory.
- Made use of new cast in various code.
- Changed use of spaces in atoi () calls.
- Switched from std::string::data () to std::string::c_str () calls.
- The next report is now a custom report. There is also a nasty
piece of logic that lets the next report exist as a custom report,
and also with it's own handleReportNext function to prep and filter
the tasks, then hand off to runCustomReport.
- "debug" now considered a valid configuration variable.
- "alias.*" now considered a valid configuration variable.
- Moved some messages over to use Context::debug.
- When a task is added, the new ID is echoed back, for convenience.
This requires a scan of the pending file, so there is a performance
hit, and the feature is controlled by the FEATURE_NEW_ID define.
- Fixed bug whereby handleRecurrence was being called after the tasks
were loaded and filtered, and thus handleRecurrence operated on a
filtered set, and failed. The fix is to move the call to before the
TDB::load call, and to add another TDB::loadPending call inside
handleRecurrence. This means TDB::load needs to be reentrant without
re-reading the file, and can therefore be called twice, with the
likelihood of there being a different filter for each call. This in
turn led to the problem whereby handleRecurrence would generate the
synthetic tasks, which then sat uncommitted in TDB::mNew. The fix
for this is that every call to TDB::loadPending gets the contents of
TDB::mNew appended (with correct IDs). This bug is what you might
call a good one.
- Fixed bug that caused colorization to be way, way off. Silly
mistake.
- Fixed bug whereby due dates and durations were stored as-is, but
should have been converted.
- On a related note, added Date::toEpochString,
Duration::operator (std::string).
- TDB::load can entirely skip the loading of completed.data if the
specified filter is just so.
- Added FEATURE_TDB_OPT definition to allow disabling of this.
- Fixed bug that meant Task::composeF4 added a newline, but Task::parse
did not expect a newline. This caused Task::determineVersion to
detect a format 1 encoding and throw. Changed TDB::load to not remove
any \n characters, and Task::parse to accept lines either with or
without.
- Modified Record::get* methods to be const.
- Implemented TDB2::add.
- Renamed Task::valid to Task::validate.
- Implemented Task::setEntry to default creation time.
- Fixed bug where TDB2 was opening files "rw" instead of "r+".