diff --git a/.travis.yml b/.travis.yml index f682f893..3a39d7b1 100644 --- a/.travis.yml +++ b/.travis.yml @@ -13,13 +13,13 @@ jobs: allow_failures: - rust: nightly -# From https://levans.fr/rust_travis_cache.html -# cache: -# directories: -# - /home/travis/.cargo +#From https://levans.fr/rust_travis_cache.html +cache: + directories: + - /home/travis/.cargo -# before_cache: -# - rm -rf /home/travis/.cargo/registry +before_cache: + - rm -rf /home/travis/.cargo/registry notifications: email: diff --git a/src/canvas.rs b/src/canvas.rs index 9801d398..cf54ff9d 100644 --- a/src/canvas.rs +++ b/src/canvas.rs @@ -37,6 +37,8 @@ lazy_static! { pub struct CanvasData { pub rx_display: String, pub tx_display: String, + pub total_rx_display: String, + pub total_tx_display: String, pub network_data_rx: Vec<(f64, f64)>, pub network_data_tx: Vec<(f64, f64)>, pub disk_data: Vec>, @@ -414,6 +416,8 @@ pub fn draw_data(terminal: &mut Terminal, app_state: &mu .marker(if app_state.use_dot { Marker::Dot } else { Marker::Braille }) .style(Style::default().fg(COLOUR_LIST[1])) .data(&canvas_data.network_data_tx), + Dataset::default().name(&(canvas_data.total_rx_display)), + Dataset::default().name(&(canvas_data.total_tx_display)), ]) .render(&mut f, bottom_chunks[0]); } diff --git a/src/main.rs b/src/main.rs index 0d6ca958..465c2a1f 100644 --- a/src/main.rs +++ b/src/main.rs @@ -272,6 +272,8 @@ fn main() -> error::Result<()> { canvas_data.network_data_tx = network_data.tx; canvas_data.rx_display = network_data.rx_display; canvas_data.tx_display = network_data.tx_display; + canvas_data.total_rx_display = network_data.total_rx_display; + canvas_data.total_tx_display = network_data.total_tx_display; canvas_data.disk_data = update_disk_row(&app.data); canvas_data.temp_sensor_data = update_temp_row(&app.data, &app.temperature_type); canvas_data.process_data = update_process_row(&app.data);