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

Add terraform.languageServer.ignoreSingleFileWarning setting #1031

Merged
merged 2 commits into from
Apr 7, 2022

Conversation

jpogran
Copy link
Contributor

@jpogran jpogran commented Apr 6, 2022

Adds the terraform-ls setting that controls whether warnings are shown when editing single Terraform files.

Works with hashicorp/terraform-ls#843

@jpogran jpogran self-assigned this Apr 6, 2022
@jpogran jpogran added the enhancement New feature or request label Apr 6, 2022
@jpogran jpogran added this to the v2.22.0 milestone Apr 6, 2022
@jpogran jpogran changed the title Single File Support Add terraform.languageServer.ignoreSingleFileWarning setting Apr 7, 2022
Adds the terraform-ls setting that controls whether warnings are shown when editing single Terraform files.
@jpogran jpogran marked this pull request as ready for review April 7, 2022 17:28
@jpogran jpogran requested a review from a team as a code owner April 7, 2022 17:28
Copy link
Member

@radeksimko radeksimko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, just one minor question in-line.

"scope": "resource",
"type": "boolean",
"description": "Path to the Terraform binary"
},
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there any benefit to setting default: false here as well?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good thing you asked, I missed adding a description here.

As for the setting, the const ignoreSingleFileWarning = config('terraform').get<boolean>('languageServer.ignoreSingleFileWarning', false); line in clientHandler.ts will ensure we get false if nothing is specified, but it's a good idea to be explicit in both places so I added it.

@jpogran jpogran merged commit e9f806a into main Apr 7, 2022
@jpogran jpogran deleted the single_file_support branch April 7, 2022 18:47
@github-actions
Copy link

github-actions bot commented May 8, 2022

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 8, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants