diff --git a/Makefile b/Makefile
index 1ed3617a..9de4d835 100644
--- a/Makefile
+++ b/Makefile
@@ -1,3 +1,6 @@
+SHELL = /bin/bash
+.SHELLFLAGS = -o pipefail -c
+
 guard-%:
 	@ if [ "${${*}}" = "" ]; then \
 		echo "Environment variable $* not set"; \
@@ -110,7 +113,7 @@ lint-node: compile-node
 	npm run lint --workspace packages/common/testing
 
 lint-samtemplates:
-	poetry run cfn-lint -I "SAMtemplates/**/*.y*ml" 2>&1 | grep -e "Run scan" -e "W[0-9]" -e "E[0-9]"
+	poetry run cfn-lint -I "SAMtemplates/**/*.y*ml" 2>&1 | awk '/Run scan/ { print } /^[EW][0-9]/ { print; getline; print }'
 
 lint-python:
 	poetry run flake8 scripts/*.py --config .flake8