Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce tfexec.Get() for downloading modules #176

Merged
merged 1 commit into from
Jun 9, 2021
Merged

Conversation

radeksimko
Copy link
Member

Generally it is possible and probably common to use the init command to initialize a Terraform module, which will install providers, setup remote state backend and download modules.

Sometimes it may be desirable to avoid installing providers, or initializing backends. I have one particular use case in tests for Terraform LS where I'd like to create a "mock module manifest" so that I can test some other functionality which relies on that module manifest, without having to copy around that module manifest statically. i.e. I'd like to generate "test data" programmatically via tfexec.Get(), but then mock out the rest of terraform commands.

I can't think of too many other use cases at this point, but the get command doesn't seem to be going anywhere based on docs at least, so I think it's worth supporting it.

@radeksimko radeksimko added the enhancement New feature or request label May 13, 2021
@radeksimko radeksimko requested a review from kmoe May 13, 2021 15:06
@radeksimko radeksimko merged commit 3211ef7 into main Jun 9, 2021
@radeksimko radeksimko deleted the f-get-cmd branch June 9, 2021 09:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants