aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorgithub-actions[bot] <github-actions[bot]@users.noreply.github.com>2025-01-05 08:34:03 +0000
committergithub-actions[bot] <github-actions[bot]@users.noreply.github.com>2025-01-05 08:34:03 +0000
commit87cdeb16895d64b306bfe9f440840ff55c2a76c0 (patch)
treedd97e692fd30625fc39f152abf24cc65738f7b46 /doc
parentfeat: atlas language server (#3539) (diff)
downloadnvim-lspconfig-87cdeb16895d64b306bfe9f440840ff55c2a76c0.tar
nvim-lspconfig-87cdeb16895d64b306bfe9f440840ff55c2a76c0.tar.gz
nvim-lspconfig-87cdeb16895d64b306bfe9f440840ff55c2a76c0.tar.bz2
nvim-lspconfig-87cdeb16895d64b306bfe9f440840ff55c2a76c0.tar.lz
nvim-lspconfig-87cdeb16895d64b306bfe9f440840ff55c2a76c0.tar.xz
nvim-lspconfig-87cdeb16895d64b306bfe9f440840ff55c2a76c0.tar.zst
nvim-lspconfig-87cdeb16895d64b306bfe9f440840ff55c2a76c0.zip
docs: update configs.md
skip-checks: true
Diffstat (limited to 'doc')
-rw-r--r--doc/configs.md57
-rw-r--r--doc/configs.txt57
2 files changed, 114 insertions, 0 deletions
diff --git a/doc/configs.md b/doc/configs.md
index 5163ecac..4069e4bc 100644
--- a/doc/configs.md
+++ b/doc/configs.md
@@ -17,6 +17,7 @@ Nvim by running `:help lspconfig-all`.
- [asm_lsp](#asm_lsp)
- [ast_grep](#ast_grep)
- [astro](#astro)
+- [atlas](#atlas)
- [autohotkey_lsp](#autohotkey_lsp)
- [autotools_ls](#autotools_ls)
- [awk_ls](#awk_ls)
@@ -805,6 +806,62 @@ Default config:
- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/astro.lua:9](../lua/lspconfig/configs/astro.lua#L9)
+## atlas
+
+https://github.com/ariga/atlas
+
+Language server for Atlas config and scheme files.
+
+You may also need to configure the filetype for *.hcl files:
+
+`autocmd BufNewFile,BufRead atlas.hcl set filetype=atlas-config`
+`autocmd BufNewFile,BufRead *.my.hcl set filetype=atlas-schema-mysql`
+`autocmd BufNewFile,BufRead *.pg.hcl set filetype=atlas-schema-postgresql`
+`autocmd BufNewFile,BufRead *.lt.hcl set filetype=atlas-schema-sqlite`
+`autocmd BufNewFile,BufRead *.ch.hcl set filetype=atlas-schema-clickhouse`
+`autocmd BufNewFile,BufRead *.ms.hcl set filetype=atlas-schema-mssql`
+`autocmd BufNewFile,BufRead *.rs.hcl set filetype=atlas-schema-redshift`
+`autocmd BufNewFile,BufRead *.test.hcl set filetype=atlas-test`
+`autocmd BufNewFile,BufRead *.plan.hcl set filetype=atlas-plan`
+
+or
+
+```lua
+vim.filetype.add({
+ filename = {
+ ['atlas.hcl'] = 'atlas-config',
+ },
+ pattern = {
+ ['.*/*.my.hcl'] = 'atlas-schema-mysql',
+ ['.*/*.pg.hcl'] = 'atlas-schema-postgresql',
+ ['.*/*.lt.hcl'] = 'atlas-schema-sqlite',
+ ['.*/*.ch.hcl'] = 'atlas-schema-clickhouse',
+ ['.*/*.ms.hcl'] = 'atlas-schema-mssql',
+ ['.*/*.rs.hcl'] = 'atlas-schema-redshift',
+ ['.*/*.test.hcl'] = 'atlas-test',
+ ['.*/*.plan.hcl'] = 'atlas-plan',
+ },
+})
+```
+
+Snippet to enable the language server:
+```lua
+require'lspconfig'.atlas.setup{}
+```
+
+Default config:
+- `cmd` :
+ ```lua
+ { "atlas", "tool", "lsp", "--stdio" }
+ ```
+- `filetypes` :
+ ```lua
+ { "atlas-*" }
+ ```
+- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/atlas.lua:4](../lua/lspconfig/configs/atlas.lua#L4)
+- `single_file_support` : `true`
+
+
## autohotkey_lsp
https://github.com/thqby/vscode-autohotkey2-lsp
diff --git a/doc/configs.txt b/doc/configs.txt
index 5163ecac..4069e4bc 100644
--- a/doc/configs.txt
+++ b/doc/configs.txt
@@ -17,6 +17,7 @@ Nvim by running `:help lspconfig-all`.
- [asm_lsp](#asm_lsp)
- [ast_grep](#ast_grep)
- [astro](#astro)
+- [atlas](#atlas)
- [autohotkey_lsp](#autohotkey_lsp)
- [autotools_ls](#autotools_ls)
- [awk_ls](#awk_ls)
@@ -805,6 +806,62 @@ Default config:
- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/astro.lua:9](../lua/lspconfig/configs/astro.lua#L9)
+## atlas
+
+https://github.com/ariga/atlas
+
+Language server for Atlas config and scheme files.
+
+You may also need to configure the filetype for *.hcl files:
+
+`autocmd BufNewFile,BufRead atlas.hcl set filetype=atlas-config`
+`autocmd BufNewFile,BufRead *.my.hcl set filetype=atlas-schema-mysql`
+`autocmd BufNewFile,BufRead *.pg.hcl set filetype=atlas-schema-postgresql`
+`autocmd BufNewFile,BufRead *.lt.hcl set filetype=atlas-schema-sqlite`
+`autocmd BufNewFile,BufRead *.ch.hcl set filetype=atlas-schema-clickhouse`
+`autocmd BufNewFile,BufRead *.ms.hcl set filetype=atlas-schema-mssql`
+`autocmd BufNewFile,BufRead *.rs.hcl set filetype=atlas-schema-redshift`
+`autocmd BufNewFile,BufRead *.test.hcl set filetype=atlas-test`
+`autocmd BufNewFile,BufRead *.plan.hcl set filetype=atlas-plan`
+
+or
+
+```lua
+vim.filetype.add({
+ filename = {
+ ['atlas.hcl'] = 'atlas-config',
+ },
+ pattern = {
+ ['.*/*.my.hcl'] = 'atlas-schema-mysql',
+ ['.*/*.pg.hcl'] = 'atlas-schema-postgresql',
+ ['.*/*.lt.hcl'] = 'atlas-schema-sqlite',
+ ['.*/*.ch.hcl'] = 'atlas-schema-clickhouse',
+ ['.*/*.ms.hcl'] = 'atlas-schema-mssql',
+ ['.*/*.rs.hcl'] = 'atlas-schema-redshift',
+ ['.*/*.test.hcl'] = 'atlas-test',
+ ['.*/*.plan.hcl'] = 'atlas-plan',
+ },
+})
+```
+
+Snippet to enable the language server:
+```lua
+require'lspconfig'.atlas.setup{}
+```
+
+Default config:
+- `cmd` :
+ ```lua
+ { "atlas", "tool", "lsp", "--stdio" }
+ ```
+- `filetypes` :
+ ```lua
+ { "atlas-*" }
+ ```
+- `root_dir` source (use "gF" to visit): [../lua/lspconfig/configs/atlas.lua:4](../lua/lspconfig/configs/atlas.lua#L4)
+- `single_file_support` : `true`
+
+
## autohotkey_lsp
https://github.com/thqby/vscode-autohotkey2-lsp