You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello,
looks like to implement this feature will be required to parse HCL files(with includes, locals, env variables resolving) and identify which will be the value of terragrunt_version_constraint
As far as I read, tgswitch supports figuring out the version terragrunt_version_constraint automatically. https://github.com/warrensbox/tgswitch#use-terragrunthcl-file It'll figure out the version from .terragrunt-version or terragrunt_version_constraint if a version is not explicitly mentioned
- name: 'Extract terraform and terragrunt version from terragrunt-root.hcl'
id: extract-tftg-version
run: |
tf_version=$(sed -n 's/^terraform_version_constraint.*=.*\"= \([0-9.]\+\)\"/\1/p' terragrunt-root.hcl)
tg_version=$(sed -n 's/^terragrunt_version_constraint.*=.*\"= \([0-9.]\+\)\"/\1/p' terragrunt-root.hcl)
echo "tf_version=$tf_version" | tee -a "$GITHUB_OUTPUT"
echo "tg_version=$tg_version" | tee -a "$GITHUB_OUTPUT"
Can we have this action figure out and install terragrunt version from the
terragrunt_version_constraint
in terragrunt.hcl?Additional context
This will help in keeping terragrunt version automatically updated within reason
The text was updated successfully, but these errors were encountered: