Skip to content

Commit 52aa6f2

Browse files
author
iru
committed
fix: pre-commit tf validation with errexit
1 parent 271f7dd commit 52aa6f2

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed
Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
11
#!/bin/bash
22

3-
for dir in examples/*
3+
# ensure errexit + failfast
4+
set -o errexit
5+
6+
for dir in examples*/*
47
do
58
echo validating example [$dir]
69
cd $dir
10+
terraform init
711
terraform validate
8-
cd ..
12+
cd ../..
913
done

0 commit comments

Comments
 (0)