-
Notifications
You must be signed in to change notification settings - Fork 4.9k
Add OpenTofu .tofu extension to HCL #7189
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
base: main
Are you sure you want to change the base?
Conversation
|
We're willing to see this being merged, thanks for the contribution @adalinesimonian ! |
That's great news! I just merged main into the feature branch; it'll be great to see if GitHub can get around to giving this a look when they have the time. :) |
|
FYI gitlab already patch their vendoring version but also add an alias |
Just rebased off main and added the |
9a105d9 to
3bb422a
Compare
|
@lildude any chance this could be reviewed? |
3bb422a to
1563504
Compare
|
Usage it reviewed whenever a new release is made. I do not comment to say usage hasn't met as this would lead to a lot of unnecessary noise so no news means usage hasn't been met. I'll review again when I make the next release. |
|
Thanks! Usage means this popularity assessment? Which criteria weren't yet met?
I see 2.2k files in the search result now. Was that not true in September? Just trying to understand the typical cadence, as this seems to be a similar number of search results as for |
Furthermore, this mode of operation is not as relevant for this extension. Indeed, it is still possible to write most files in .hcl format, and GitHub's lack of support for .tofu does not encourage its adoption on github only project. |
|
Hey, that will be really helpful. Waiting for that too in our company (and I know others too). |
This is exactly the same case at my organisation. |
Adds .tofu extension to HCL, as used by OpenTofu.
Description
OpenTofu supports .tf as used by Terraform, but uses .tofu to allow OpenTofu-specific behaviour to be ignored by Terraform. The project has also reserved any new OpenTofu syntax for compatibility reasons to .tofu files alone. New language-changing syntax that would require adjustments to syntax highlighting has not been introduced, so therefore I believe it is safe to simply add .tofu as an extension for HCL.
Adoption of .tofu seems to have been more rapid amongst end-users, who likely have private repositories. While there are still several hundred results on GitHub, most lengthy, good examples of HCL in use with the .tofu extension were likely going to be behind this wall. Therefore, I wrote a length-enough example that resembles code I have in production at my employer and with other projects. I am happy to have it licensed under Linguist's MIT licence.
Checklist: