Showing the changes to git-command/src (1 of 1 file). Show all
Unified · Split
| @@ -91,15 +91,15 @@ mod prepare { · 90 unmodified lines | |||
| 91 | /// | 91 | /// |
| 92 | /// Note that the default IO is configured for typical API usage, that is | 92 | /// Note that the default IO is configured for typical API usage, that is |
| 93 | /// | 93 | /// |
| 94 | /// - `stdin` is null | 94 | /// - `stdin` is null to prevent blocking unexpectedly on consumption of stdin |
| 95 | /// - `stdout` is captured. | 95 | /// - `stdout` is captured for consumption by the caller |
| 96 | /// - `stderr` is null | 96 | /// - `stderr` is inherited to allow the command to provide context to the user |
| 97 | pub fn prepare(cmd: impl Into<OsString>) -> Prepare { | 97 | pub fn prepare(cmd: impl Into<OsString>) -> Prepare { |
| 98 | Prepare { | 98 | Prepare { |
| 99 | command: cmd.into(), | 99 | command: cmd.into(), |
| 100 | stdin: std::process::Stdio::null(), | 100 | stdin: std::process::Stdio::null(), |
| 101 | stdout: std::process::Stdio::piped(), | 101 | stdout: std::process::Stdio::piped(), |
| 102 | stderr: std::process::Stdio::null(), | 102 | stderr: std::process::Stdio::inherit(), |
| 103 | args: Vec::new(), | 103 | args: Vec::new(), |
| 104 | use_shell: false, | 104 | use_shell: false, |
| 105 | } | 105 | } |