diff options
Diffstat (limited to 'src/main.rs')
-rw-r--r-- | src/main.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main.rs b/src/main.rs index 5e6eab5e..1de9375b 100644 --- a/src/main.rs +++ b/src/main.rs @@ -65,6 +65,12 @@ pub mod errors { #[cfg(not(tarpaulin_include))] fn main() -> std::io::Result<()> { + // Do this first because both parsing all the input in `run_app()` and + // listing all processes takes about 50ms on Linux. + // It also improves the chance that the calling process is still around when + // input is piped into delta (e.g. `git show --word-diff=color | delta`). + utils::process::start_determining_calling_process_in_thread(); + // Ignore ctrl-c (SIGINT) to avoid leaving an orphaned pager process. // See https://github.com/dandavison/delta/issues/681 ctrlc::set_handler(|| {}) |