From f88153f62b024d1c2ef82c5ac7ae9002e4fe2967 Mon Sep 17 00:00:00 2001 From: Jesse Luehrs Date: Sun, 27 Oct 2019 13:33:47 -0400 Subject: add terminal resizing functionality to keep the process's pty size in sync with the size of the user's terminal --- examples/shell.rs | 2 ++ 1 file changed, 2 insertions(+) (limited to 'examples/shell.rs') diff --git a/examples/shell.rs b/examples/shell.rs index 682c008..2cd7ba2 100644 --- a/examples/shell.rs +++ b/examples/shell.rs @@ -15,6 +15,7 @@ fn main() { &args, input::evented_stdin::Stdin::new(), ); + let process = tokio_pty_process_stream::ResizingProcess::new(process); let _raw = crossterm::RawScreen::into_raw_mode().unwrap(); tokio::run( @@ -33,6 +34,7 @@ fn main() { tokio_pty_process_stream::Event::CommandExit { .. } => {} + tokio_pty_process_stream::Event::Resize { .. } => {} } futures::future::ok(()) }) -- cgit v1.2.3-54-g00ecf