diff options
| author | Andy Lindeman <andy@lindeman.io> | 2020-05-16 15:59:23 -0400 |
|---|---|---|
| committer | Andy Lindeman <andy@lindeman.io> | 2020-05-16 16:06:21 -0400 |
| commit | 5e7401ab7735b1e955225ad270912f5bbecdfc23 (patch) | |
| tree | 7497a335ce068dd04ffcb53333d264d2891d219d /lua/nvim_lsp/terraformls.lua | |
| parent | [docgen] Update README.md (diff) | |
| download | nvim-lspconfig-5e7401ab7735b1e955225ad270912f5bbecdfc23.tar nvim-lspconfig-5e7401ab7735b1e955225ad270912f5bbecdfc23.tar.gz nvim-lspconfig-5e7401ab7735b1e955225ad270912f5bbecdfc23.tar.bz2 nvim-lspconfig-5e7401ab7735b1e955225ad270912f5bbecdfc23.tar.lz nvim-lspconfig-5e7401ab7735b1e955225ad270912f5bbecdfc23.tar.xz nvim-lspconfig-5e7401ab7735b1e955225ad270912f5bbecdfc23.tar.zst nvim-lspconfig-5e7401ab7735b1e955225ad270912f5bbecdfc23.zip | |
Add .terraform/ as a root dir for terraformls
`terraform init` creates .terraform/ and is a better indicator of the
root than .git/ in many cases
Diffstat (limited to 'lua/nvim_lsp/terraformls.lua')
| -rw-r--r-- | lua/nvim_lsp/terraformls.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lua/nvim_lsp/terraformls.lua b/lua/nvim_lsp/terraformls.lua index 0a84fe2d..3f94a036 100644 --- a/lua/nvim_lsp/terraformls.lua +++ b/lua/nvim_lsp/terraformls.lua @@ -5,7 +5,7 @@ configs.terraformls = { default_config = { cmd = {"terraform-lsp"}; filetypes = {"terraform"}; - root_dir = util.root_pattern(".git"); + root_dir = util.root_pattern(".terraform", ".git"); }; docs = { vscode = "mauve.terraform"; @@ -16,7 +16,7 @@ Terraform language server You can use [released binary](https://github.com/juliosueiras/terraform-lsp/releases) or [build](https://github.com/juliosueiras/terraform-lsp#building) your own. ]]; default_config = { - root_dir = [[root_pattern(".git")]]; + root_dir = [[root_pattern(".terraform", ".git")]]; }; }; } |
