Skip to content

Commit 86695ef

Browse files
committed
Update to modify or create tflint config
1 parent 750d906 commit 86695ef

File tree

1 file changed

+9
-14
lines changed

1 file changed

+9
-14
lines changed

.circleci/config.yml

Lines changed: 9 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -37,20 +37,15 @@ jobs:
3737
if [ -f '.tflint.hcl' ]; then
3838
sed -i "/terraform_version =/s/\".*\"/\"${tf_ver}\"/" .tflint.hcl
3939
else
40-
# TODO: Create ignore_module section of all modules
41-
# grep -h '[^a-zA-Z]source[ =]' *.tf | sed -r 's/.*=\s+//' | sort -u
42-
echo -e "config {\nterraform_version = \"${tf_ver}\"\ndeep_check = true\n}" > .tflint.hcl
43-
fi
44-
echo "tflint configuration modified:"
45-
cat .tflint.hcl
46-
{
47-
echo -e "config {\nterraform_version = \"${tf_ver}\"\ndeep_check = true\nignore_module = {"
48-
for module in $(grep -h '[^a-zA-Z]source[ =]' *.tf | sed -r 's/.*=\s+//' | sort -u); do
49-
echo "${module} = true"
50-
done
51-
echo "}}"
52-
} > .tflint.hcl
53-
echo "tflint configuration NEW:"
40+
{
41+
echo -e "config {\nterraform_version = \"${tf_ver}\"\ndeep_check = true\nignore_module = {"
42+
for module in $(grep -h '[^a-zA-Z]source[ =]' *.tf | sed -r 's/.*=\s+//' | sort -u); do
43+
echo "${module} = true"
44+
done
45+
echo "}}"
46+
} > .tflint.hcl
47+
fi
48+
echo "tflint configuration:"
5449
cat .tflint.hcl
5550
- run:
5651
# Not supporting modules from registry ?? v0.5.4

0 commit comments

Comments
 (0)