LJ6NSNMT4MVRLROHDZZAYPJBR7ZLUQGHFSOCILNK2FJFZZUS6OTQC
table.force_no_tty();
}
let mut header = vec!["tmn"];
if host {
header.push("host")
};
if duration {
header.push("duration")
};
if status {
header.push("res")
};
if show_session {
header.push("ses");
}
if show_pwd {
header.push("pwd");
}
header.push("cmd");
let stdout = std::io::stdout();
let mut handle = stdout.lock();
table.set_header(header);
handle
.write_all(row.join("\t").as_bytes())
.map_err(Error::WriteStdout)?;
handle.write_all(b"\n").map_err(Error::WriteStdout)?;
}
} else {
let mut table = Table::new();
table.load_preset(" ");
table.set_content_arrangement(comfy_table::ContentArrangement::Dynamic);
table.add_row(row);
}
if host {
row.push(entry.hostname)
}
if duration {
row.push(format_duration(entry.time_start, entry.time_finished)?)
}
if status {
row.push(format!("{}", entry.result))
}
if show_session {
row.push(format_uuid(entry.session_id));
}
if show_pwd {
row.push(format_pwd(&entry.pwd)?);
}
row.push(format_command(&entry.command, no_format));