From 195b70db8c697e44b65beeb83abe4c283cd4cda4 Mon Sep 17 00:00:00 2001 From: "Joseph C. Sible" <josephcsible@users.noreply.github.com> Date: Fri, 13 Dec 2024 23:06:49 -0500 Subject: [PATCH] Use unless instead of when and not --- src/ShellCheck/Checks/ShellSupport.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ShellCheck/Checks/ShellSupport.hs b/src/ShellCheck/Checks/ShellSupport.hs index 2ec4cf7..f228832 100644 --- a/src/ShellCheck/Checks/ShellSupport.hs +++ b/src/ShellCheck/Checks/ShellSupport.hs @@ -330,7 +330,7 @@ checkBashisms = ForShell [Sh, Dash, BusyboxSh] $ \t -> do | t `isCommand` "echo" && argString `matches` flagRegex = if isBusyboxSh then - when (not (argString `matches` busyboxFlagRegex)) $ + unless (argString `matches` busyboxFlagRegex) $ warnMsg (getId arg) 3036 "echo flags besides -n and -e" else if isDash then