on master help sign in
fix(lsp): divide hcl into seperate languages (#2244)
commit5ca8dfe57c044227274b73f9169ae68cebf1d074 authorLukas <lukas.hoehl@accso.de> dateSat 23 Apr 2022, 23:08 (5 years ago) parent6047506
2 files changed+14−2
book/src/generated/lang-support.md+1 languages.toml+13−2
book/src/generated/lang-support.md+1
@@ -73,6 +73,7 @@
7373| svelte | ✓ | | ✓ | `svelteserver` |
7474| swift | ✓ | | | `sourcekit-lsp` |
7575| tablegen | ✓ | ✓ | ✓ | |
76+| tfvars | | | | `terraform-ls` |
7677| toml | ✓ | | | |
7778| tsq | ✓ | | | |
7879| tsx | ✓ | | | `typescript-language-server` |
languages.toml+13−2
@@ -1039,17 +1039,28 @@ source = { git = "https://github.com/fwcd/tree-sitter-kotlin", rev = "a4f71eb9b8
10391039name = "hcl"
10401040scope = "source.hcl"
10411041injection-regex = "(hcl|tf|nomad)"
1042−file-types = ["hcl", "tf", "tfvars", "nomad"]
1042+file-types = ["hcl", "tf", "nomad"]
10431043roots = []
10441044comment-token = "#"
10451045indent = { tab-width = 2, unit = " " }
1046−language-server = { command = "terraform-ls", args = ["serve"] }
1046+language-server = { command = "terraform-ls", args = ["serve"], language-id = "terraform" }
10471047auto-format = true
10481048
10491049[[grammar]]
10501050name = "hcl"
10511051source = { git = "https://github.com/MichaHoffmann/tree-sitter-hcl", rev = "3cb7fc28247efbcb2973b97e71c78838ad98a583" }
10521052
1053+[[language]]
1054+name = "tfvars"
1055+scope = "source.tfvars"
1056+file-types = ["tfvars"]
1057+roots = []
1058+comment-token = "#"
1059+indent = { tab-width = 2, unit = " " }
1060+language-server = { command = "terraform-ls", args = ["serve"], language-id = "terraform-vars" }
1061+auto-format = true
1062+grammar = "hcl"
1063+
10531064[[language]]
10541065name = "org"
10551066scope = "source.org"