Skip to content

Commit

Permalink
update table
Browse files Browse the repository at this point in the history
  • Loading branch information
postrequest committed Apr 12, 2021
1 parent 79c146e commit 388a528
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions src/util/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ use rustyline::Editor;
use server::links::Links;
use std::sync::mpsc;

use prettytable::Table;
use prettytable::format;
use prettytable::{format, Table};

// internal packages
use crate::server;
Expand Down Expand Up @@ -332,12 +331,12 @@ fn links_list(links: web::Data<Links>, all: bool) {
}
table.add_row(row![
tmp[iu].name,
format!("{:?}", tmp[iu].link_type),
Fr -> format!("{:?}", tmp[iu].link_type),
tmp[iu].platform,
format!("{}\\{}", tmp[iu].link_hostname, tmp[iu].link_username),
FB -> format!("{}\\{}", tmp[iu].link_hostname, tmp[iu].link_username),
tmp[iu].internal_ip,
tmp[iu].last_checkin,
format!("{:?}", tmp[iu].status),
Fc -> tmp[iu].last_checkin,
bFg -> format!("{:?}", tmp[iu].status),
]);
}
table.printstd();
Expand Down

0 comments on commit 388a528

Please sign in to comment.