Skip to content

Commit 517fbcc

Browse files
committed
fix(scripts): add usage message for missing args in tf-module.sh
1 parent 582fbec commit 517fbcc

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

scripts/tf-module.sh

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,15 @@
1111
# 2 drift detected (plan mode) or user aborted with 'q' (apply mode)
1212
set -euo pipefail
1313

14+
if [[ $# -lt 3 ]]; then
15+
echo "Usage: $0 <plan|apply> <auto_approve> <module_path>"
16+
echo ""
17+
echo " plan|apply terraform command to run"
18+
echo " auto_approve 0 (prompt) | 1 (no prompt)"
19+
echo " module_path relative to repo root, e.g. providers/gcp/org"
20+
exit 1
21+
fi
22+
1423
CMD="$1"
1524
AUTO_APPROVE="$2"
1625
MODULE="$3"

0 commit comments

Comments
 (0)