|
@@ -3,6 +3,7 @@ use clap::ArgMatches;
|
|
|
use ffsend_api::config::SEND_DEFAULT_EXPIRE_TIME;
|
|
|
use prettytable::{Cell, format::FormatBuilder, Row, Table};
|
|
|
|
|
|
+use client::to_duration;
|
|
|
use cmd::matcher::{debug::DebugMatcher, main::MainMatcher, Matcher};
|
|
|
use error::ActionError;
|
|
|
use util::{features_list, format_bool, format_duration};
|
|
@@ -42,6 +43,28 @@ impl<'a> Debug<'a> {
|
|
|
Cell::new(matcher_main.history().to_str().unwrap_or("?")),
|
|
|
]));
|
|
|
|
|
|
+ // The timeouts
|
|
|
+ table.add_row(Row::new(vec![
|
|
|
+ Cell::new("Timeout:"),
|
|
|
+ Cell::new(
|
|
|
+ &to_duration(matcher_main.timeout())
|
|
|
+ .map(|t| format_duration(
|
|
|
+ Duration::from_std(t).expect("failed to convert timeout duration"),
|
|
|
+ ))
|
|
|
+ .unwrap_or("disabled".into())
|
|
|
+ ),
|
|
|
+ ]));
|
|
|
+ table.add_row(Row::new(vec![
|
|
|
+ Cell::new("Transfer timeout:"),
|
|
|
+ Cell::new(
|
|
|
+ &to_duration(matcher_main.transfer_timeout())
|
|
|
+ .map(|t| format_duration(
|
|
|
+ Duration::from_std(t).expect("failed to convert transfer timeout duration"),
|
|
|
+ ))
|
|
|
+ .unwrap_or("disabled".into())
|
|
|
+ ),
|
|
|
+ ]));
|
|
|
+
|
|
|
// The default host
|
|
|
table.add_row(Row::new(vec![
|
|
|
Cell::new("Default expiry:"),
|