mirror of
https://github.com/GothenburgBitFactory/taskwarrior.git
synced 2025-06-26 10:54:26 +02:00
CmdCustom
- Now places ( ) around the custom report filter. This gives it a chance at allowing 'or' and 'xor' operators when combined with a command lne filter.
This commit is contained in:
parent
5ac3db3168
commit
cf5eb73f04
1 changed files with 3 additions and 1 deletions
|
@ -63,6 +63,8 @@ int CmdCustom::execute (std::string& output)
|
|||
std::string reportLabels = context.config.get ("report." + _keyword + ".labels");
|
||||
std::string reportSort = context.config.get ("report." + _keyword + ".sort");
|
||||
std::string reportFilter = context.config.get ("report." + _keyword + ".filter");
|
||||
if (reportFilter != "")
|
||||
reportFilter = "( " + reportFilter + " )";
|
||||
|
||||
std::vector <std::string> columns;
|
||||
split (columns, reportColumns, ',');
|
||||
|
@ -85,7 +87,7 @@ int CmdCustom::execute (std::string& output)
|
|||
|
||||
// Prepend the argument list with those from the report filter.
|
||||
std::vector <std::string> filterArgs;
|
||||
Lexer::split (filterArgs, reportFilter);
|
||||
Lexer::token_split (filterArgs, reportFilter);
|
||||
std::vector <std::string>::reverse_iterator arg;
|
||||
for (arg = filterArgs.rbegin (); arg != filterArgs.rend (); ++ arg)
|
||||
context.parser.captureFirst (*arg);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue