This commit is contained in:
Dustin J. Mitchell
2020-11-29 11:23:19 -05:00
parent 42d988d601
commit 29ab993397
3 changed files with 57 additions and 0 deletions

View File

@@ -2,6 +2,7 @@ use crate::table;
use clap::{App, ArgMatches, SubCommand as ClapSubCommand};
use failure::Fallible;
use prettytable::{cell, row, Table};
use taskchampion::Status;
use crate::cmd::{ArgMatchResult, CommandInvocation};
@@ -28,6 +29,9 @@ subcommand_invocation! {
t.set_format(table::format());
t.set_titles(row![b->"id", b->"act", b->"description"]);
for (uuid, task) in replica.all_tasks().unwrap() {
if task.get_status() != Status::Pending {
continue;
}
let mut id = uuid.to_string();
if let Some(i) = replica.get_working_set_index(&uuid)? {
id = i.to_string();