cunymatthieu / tgenv

Terragrunt version manager
MIT License
223 stars 70 forks source link

Fixed support for automatically installing terragrunt #26

Closed trumpet2012 closed 2 years ago

trumpet2012 commented 2 years ago

The current implementation of tgenv-version-name errors out if the version specified isn't already downloaded and installed.

I pulled these changes from the latest tfenv-version-name file from the tfenv repo: https://github.com/tfutils/tfenv/blob/master/libexec/tfenv-version-name.

This also adds support for using a TGENV_CONFIG_DIR environment variable to install terragrunt versions into a user defined directory. This works just like the TFENV_CONFIG_DIR from tfenv and is ported over from their code.

I just switched all references from terraform to terragrunt.

Leaving this here in case anyone else finds it useful.