diff --git a/src/command.rs b/src/command.rs index 88629a0..6337fd1 100644 --- a/src/command.rs +++ b/src/command.rs @@ -66,6 +66,7 @@ fn run_inner(command_request: &CommandRequest) -> Result { let mut command = Command::new(&request.command); command + .stdin(Stdio::piped()) .stdout(Stdio::piped()) .stderr(Stdio::piped()) .args(&request.hidden_options); @@ -84,8 +85,6 @@ fn run_inner(command_request: &CommandRequest) -> Result { command.arg(&request.cmdline); } - command.stdin(Stdio::piped()); - std::mem::drop(request); command.spawn() diff --git a/src/ui.rs b/src/ui.rs index 97e1888..43b2bfb 100644 --- a/src/ui.rs +++ b/src/ui.rs @@ -86,6 +86,12 @@ pub fn draw(f: &mut Frame, app: &App) { // Render the output in the outpout region if let Some(ref command_result) = command_options.command_result { ui_output(f, chunks[1], &mut render_states, command_result); + } else { + f.render_widget( + Block::default().title("Output") + .borders(Borders::ALL), + chunks[1] + ) } f.set_cursor(