Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,6 @@ pug.log
go.work

dist/

# for people whose editor generates tags
*tags*
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -310,7 +310,7 @@ When `terragrunt` is specified as the program executable, Pug enables "terragrun

* Modules are detected via the presence of a `terragrunt.hcl` file. (You may want to rename the top-level `terragrunt.hcl` file to something else otherwise it is mis-detected as a module).
* Module dependencies are supported. After modules are loaded, a task invokes `terragrunt graph-dependencies`, from which dependencies are parsed and configured in Pug. If you apply multiple modules Pug ensures their dependencies are respected, applying modules in topological order. If you apply a *destroy* plan for multiple modules, modules are applied in reverse topological order.
* The flag `--terragrunt-non-interactive` is added to commands.
* The flag `--non-interactive` is added to commands.

## Multiple terraform versions

Expand Down
10 changes: 9 additions & 1 deletion hacks/rebuild.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,13 @@

while true; do
go build -o _build/pug && pkill -f '_build/pug'
inotifywait -e attrib $(find . -name '*.go') || exit

# OSX doesn't have inotifywait, so we use fswatch instead
if [[ "$(uname)" == "Darwin" ]]; then
fswatch -e .git -o $(find . -name '*.go') || exit
elif [[ "$(uname)" == "Linux" ]]; then
inotifywait -e attrib $(find . -name '*.go') || exit
else
echo "Unknown OS: $(uname)"
fi
done
2 changes: 1 addition & 1 deletion internal/task/task.go
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ func (f *factory) newTask(spec Spec) (*Task, error) {
// Perhaps use constants for terraform, tofu, and terragrunt.
if task.Program == "terragrunt" && f.terragrunt {
task.AdditionalEnv = append(task.AdditionalEnv, "TERRAGRUNT_FORWARD_TF_STDOUT=1")
task.Args = append(task.Args, "--terragrunt-non-interactive")
task.Args = append(task.Args, "--non-interactive")
}
return task, nil
}
Expand Down