From ab39b45e304474813ffd559dea4c02b28360172f Mon Sep 17 00:00:00 2001 From: Martin Puppe Date: Wed, 2 Dec 2020 17:21:31 +0100 Subject: [PATCH] Exit with status 1 if sub-process fails --- secrets | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/secrets b/secrets index 41f6850..87cc230 100755 --- a/secrets +++ b/secrets @@ -219,7 +219,11 @@ EOF (handle-stdin stdin phase-channel basedir files)))]) (thread-wait stderr-thread) - (thread-wait stdin-thread)))) + (thread-wait stdin-thread)) + (subprocess-wait sp) + (let ([status (subprocess-status sp)]) + (unless (equal? status 0) + (exit 1))))) (void))