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 support for tfvars+tfstate #1

Closed
radeksimko opened this issue May 21, 2015 · 9 comments · Fixed by #39
Closed

Add support for tfvars+tfstate #1

radeksimko opened this issue May 21, 2015 · 9 comments · Fixed by #39

Comments

@radeksimko
Copy link
Collaborator

I haven't looked at the tmLanguage specification, but it would be nice to define some kind of mapping for the following:

  • *.tfvars => *.ini (there may be some small differences in escaping, but I'd just ignore that for any first implementation)
  • *.tfstate => *.json

btw. thanks again for the effort invested into this! 👍

@alexlouden
Copy link
Collaborator

My pleasure 😃 - happy to help. I don't have time to do any more on this for now, but the following should help whoever is keen:

Here are the docs I've been working from:

And I've been using the following Sublime packages:

And here are a few good examples:

@radeksimko
Copy link
Collaborator Author

I don't have time to do any more on this for now

That's understandable, I chatted with a few folks from the Terraform core team about eventually moving this under /hashicorp/Terraform.tmLanguage and they said they're open, but only if there will be a guaranteed maintainer since not many people in Hashicorp use Sublime Text.

That said, I will probably send a few PRs to cover the above ^ and then eventually add this repo (alexlouden/Terraform.tmLanguage) to the official package repository (if you don't mind), so it's easier to find & install for anyone.

@alexlouden
Copy link
Collaborator

I've added you as a contributor - please feel free to make any changes/additions as you like! Very happy for it to be listed on package control - I was holding off to check you guys were ok with it.

@euforia
Copy link

euforia commented Aug 5, 2016

@alexlouden: i've forked your code to start making it geared for hcl rather than terraform specifically. https://github.com/euforia/HCL.tmLanguage

I've changed some of the snippet scopes which still need work and also add .hcl file extension.

I wasn't sure what plan was for this project but was wondering if you were open to that idea and would be happy to contribute.

@radeksimko: if you don't mind me asking - what is being used for HCL syntax highlighting ?

@radeksimko
Copy link
Collaborator Author

radeksimko commented Aug 7, 2016

@euforia

I wasn't sure what plan was for this project but was wondering if you were open to that idea and would be happy to contribute.

Just linking a (positive) answer here: hashicorp/terraform#2030 (comment)

if you don't mind me asking - what is being used for HCL syntax highlighting ?

Do you mean on github.com? We had a debate about what the short-term solution (language closest to HCL) should be and we ended up with Ruby, although JavaScript was also pretty close. None of those are ideal, so (I believe) there's an obvious interest in the community to eventually leverage repository like this in github/linguist to enable real HCL syntax highlighting on github.com.

github-linguist/linguist#1899
github-linguist/linguist#2527

If you were rather asking for definition/docs of HCL itself, the best source is probably https://github.com/hashicorp/hcl 😉

@alexlouden
Copy link
Collaborator

Hey @euforia / @radeksimko - as of #19 this repo now supports for the .hcl file extension. I've found some spare time and have been doing a little more on this project recently, and I'm keen to keep maintaining it with bugfixes/improvements going forward.

github-linguist/linguist#3392 has just been merged, which means this repo will be used for syntax highlighting .hcl and .tf on Github.com pretty soon (when linguist is next released). 🎉

@radeksimko
Copy link
Collaborator Author

radeksimko commented Feb 20, 2017

@alexlouden That is great, I really appreciate the time you spent on this, thanks! 👍 🎉

Can't wait for the next release of linguist :)

@alexlouden
Copy link
Collaborator

alexlouden commented Feb 22, 2017

Looks like it's released! Not sure when it'll hit github.com

@alexlouden
Copy link
Collaborator

@radeksimko Yew!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants