taskwarrior-tui icon indicating copy to clipboard operation
taskwarrior-tui copied to clipboard

Preset filters from command line

Open kiil opened this issue 2 years ago • 3 comments

Description

I launch taskwarrior-tui from some icons running different command lines and it would be helpful if I could preset filters so taskwarrior-tui would show different tasks from the get go.

Solution

I know it is already possible to select specific reports via the --report flag, but being able to run taskwarrior-tui with filters would greatly improve the flexibility of the app.

Fx

taskwarrior-tui --filter="due:today +important pri:H"

And then the app would open with these filters already set.

Even better if the filters could be simply arguments like so:

taskwarrior-tui due:today +important pri:H

kiil avatar Jul 25 '23 19:07 kiil

I believe you can set a custom filter for each report already. Does this not work for you?

e.g.:

uda.taskwarrior-tui.task-report.report-name-here.filter="due:today +important pri:H"

kdheepak avatar Jul 26 '23 15:07 kdheepak

I think I'd like to make --filter work too, so I'll keep this issue open. But the above workaround should solve your problem for now.

kdheepak avatar Jul 26 '23 15:07 kdheepak

Yes. That is possible also :)

kiil avatar Jul 26 '23 16:07 kiil