From d8a1e394ba969d6e243cf5d655986c4f530f560b Mon Sep 17 00:00:00 2001 From: Andy Stewart Date: Mon, 23 Sep 2024 06:34:44 +0800 Subject: [PATCH] Support Cucumber language. --- README.md | 1 + README.zh-CN.md | 1 + langserver/cucumber-language-server.json | 9 ++++ lsp-bridge.el | 3 ++ todo.md | 62 +++++++++++------------- 5 files changed, 43 insertions(+), 33 deletions(-) create mode 100644 langserver/cucumber-language-server.json diff --git a/README.md b/README.md index 5c17b8bc87..55964779a0 100644 --- a/README.md +++ b/README.md @@ -367,6 +367,7 @@ If your language supports mixed multi-language servers, it is recommended to che | Cmake | [cmake-language-server](https://github.com/regen100/cmake-language-server) | `pip install cmake-language-server` | | Cobol | [che-che4z-lsp-for-cobol](https://github.com/eclipse-che4z/che-che4z-lsp-for-cobol) | | | CSS | [vscode-css-language-server](https://github.com/hrsh7th/vscode-langservers-extracted) | `npm i -g vscode-langservers-extracted` | +| Cucumber | [cucumber-language-server](https://github.com/cucumber/language-server) | `npm install @cucumber/language-server` | | C# | [csharp-ls](https://github.com/razzmatazz/csharp-language-server) | Use command `dotnet tool install -g csharp-ls` install csharp-ls, `lsp-bridge-csharp-lsp-server` set to `csharp-ls` | | | [omnisharp-dotnet](https://github.com/OmniSharp/omnisharp-roslyn) | OmniSharp is a .NET development platform based on Roslyn workspaces. use `M-x lsp-bridge-install-omnisharp` to install it. `lsp-bridge-csharp-lsp-server` set to `omnisharp-dotnet` (6.0) | | | [omnisharp-mono](https://github.com/OmniSharp/omnisharp-roslyn) | OmniSharp is a .NET development platform based on Roslyn workspaces. use `M-x lsp-bridge-install-omnisharp` to install it. `lsp-bridge-csharp-lsp-server` set to `omnisharp-mono` | diff --git a/README.zh-CN.md b/README.zh-CN.md index 8a15c2308c..190f1b15e5 100644 --- a/README.zh-CN.md +++ b/README.zh-CN.md @@ -363,6 +363,7 @@ lsp-bridge 针对许多语言都提供 2 个以上的语言服务器支持, | Cmake | [cmake-language-server](https://github.com/regen100/cmake-language-server) | `pip install cmake-language-server` | | Cobol | [che-che4z-lsp-for-cobol](https://github.com/eclipse-che4z/che-che4z-lsp-for-cobol) | | | CSS | [vscode-css-language-server](https://github.com/hrsh7th/vscode-langservers-extracted) | `npm i -g vscode-langservers-extracted` | +| Cucumber | [cucumber-language-server](https://github.com/cucumber/language-server) | `npm install @cucumber/language-server` | | C# | [omnisharp-dotnet](https://github.com/OmniSharp/omnisharp-roslyn) | OmniSharp 是 .NET 开发平台, 使用命令 `M-x lsp-bridge-install-omnisharp` 来安 OmniSharp, 默认是 `omnisharp-mono`. `lsp-bridge-csharp-lsp-server` 设置成 `omnisharp-dotnet` | | | [omnisharp-mono](https://github.com/OmniSharp/omnisharp-roslyn) | OmniSharp 是 .NET 开发平台, 使用命令 `M-x lsp-bridge-install-omnisharp` 来安 OmniSharp, 默认是 `omnisharp-mono`. `lsp-bridge-csharp-lsp-server` 设置成 `omnisharp-mono` | | C++ | [clangd](https://github.com/clangd/clangd) | 需要在项目根目录配置好 `compile_commands.json` 或 `CMakeLists.txt` 文件 | diff --git a/langserver/cucumber-language-server.json b/langserver/cucumber-language-server.json new file mode 100644 index 0000000000..2446d4c3db --- /dev/null +++ b/langserver/cucumber-language-server.json @@ -0,0 +1,9 @@ +{ + "name": "cucumber-language-server", + "languageId": "cucumber", + "command": [ + "cucumber-language-server", + "--stdio" + ], + "settings": {} +} diff --git a/lsp-bridge.el b/lsp-bridge.el index e4ba8e60f8..d40a72a5c5 100644 --- a/lsp-bridge.el +++ b/lsp-bridge.el @@ -587,6 +587,7 @@ Possible choices are basedpyright_ruff, pyright_ruff, pyright-background-analysi (solidity-mode . "solidity") (gleam-ts-mode . "gleam") (ada-mode . "ada-language-server") + (feature-mode . "cucumber-language-server") (rego-mode . "regal") (puppet-mode . "puppet-languageserver") (nxml-mode . lsp-bridge-xml-lsp-server) @@ -705,6 +706,7 @@ Possible choices are basedpyright_ruff, pyright_ruff, pyright-background-analysi solidity-mode-hook gleam-ts-mode-hook ada-mode-hook + feature-mode-hook rego-mode-hook puppet-mode-hook nxml-mode-hook @@ -777,6 +779,7 @@ you can customize `lsp-bridge-get-workspace-folder' to return workspace folder p (raku-mode . raku-indent-offset) ; Perl6/Raku (erlang-mode . erlang-indent-level) ; Erlang (ada-mode . ada-indent) ; Ada + (feature-mode . feature-indent-level) ; Cucumber (rego-mode . lsp-bridge-indent-two-level) ; Rego (puppet-mode . puppet-indent-level) ; Puppet (nxml-mode . lsp-bridge-indent-two-level) ; XML diff --git a/todo.md b/todo.md index f31c74a637..4a79fb5c9e 100644 --- a/todo.md +++ b/todo.md @@ -4,64 +4,60 @@ Below LSP server haven't supported, PR are welcome. ;) 2. **PowerShell**: [github.com/PowerShell/PowerShellEditorServices](https://github.com/PowerShell/PowerShellEditorServices) (need env to test start command) -3. **Cucumber (Gherkin)**: cucumber/language-server +3. **Coq**: coq-lsp -4. **Gauge**: [github.com/getgauge/gauge](https://github.com/getgauge/gauge) +4. **Delphi**: Embarcadero (Proprietary - DelphiLSP) -5. **Coq**: coq-lsp +5. **BibTeX**: [github.com/oncomouse/citation-langserver](https://github.com/oncomouse/citation-langserver) -6. **Delphi**: Embarcadero (Proprietary - DelphiLSP) +6. **JSON-LD**: [github.com/ajuvercr/jsonld-lsp](https://github.com/ajuvercr/jsonld-lsp) -7. **BibTeX**: [github.com/oncomouse/citation-langserver](https://github.com/oncomouse/citation-langserver) +7. **Ballerina**: [github.com/ballerina-platform/ballerina-lang/tree/master/language-server](https://github.com/ballerina-platform/ballerina-lang/tree/master/language-server) -8. **JSON-LD**: [github.com/ajuvercr/jsonld-lsp](https://github.com/ajuvercr/jsonld-lsp) +8. **Langium**: [github.com/langium/langium](https://github.com/langium/langium) -9. **Ballerina**: [github.com/ballerina-platform/ballerina-lang/tree/master/language-server](https://github.com/ballerina-platform/ballerina-lang/tree/master/language-server) +9. **Odin**: [github.com/DanielGavin/ols](https://github.com/DanielGavin/ols) -10. **Langium**: [github.com/langium/langium](https://github.com/langium/langium) +10. **Xtext** (Any Language): [github.com/eclipse/xtext-core](https://github.com/eclipse/xtext-core) -11. **Odin**: [github.com/DanielGavin/ols](https://github.com/DanielGavin/ols) +11. **ActionScript3**: [github.com/BowlerHatLLC/vscode-nextgenas/tree/master/language-server](https://github.com/BowlerHatLLC/vscode-nextgenas/tree/master/language-server) -12. **Xtext** (Any Language): [github.com/eclipse/xtext-core](https://github.com/eclipse/xtext-core) +12. **Raku**: [github.com/bscan/RakuNavigator](https://github.com/bscan/RakuNavigator) -13. **ActionScript3**: [github.com/BowlerHatLLC/vscode-nextgenas/tree/master/language-server](https://github.com/BowlerHatLLC/vscode-nextgenas/tree/master/language-server) +13. **Flux**: [github.com/influxdata/flux-lsp](https://github.com/influxdata/flux-lsp) -14. **Raku**: [github.com/bscan/RakuNavigator](https://github.com/bscan/RakuNavigator) +14. **SPARQL**: [github.com/stardog-union/stardog-language-servers/tree/master/packages/sparql-language-server](https://github.com/stardog-union/stardog-language-servers/tree/master/packages/sparql-language-server) -15. **Flux**: [github.com/influxdata/flux-lsp](https://github.com/influxdata/flux-lsp) +15. **Turtle**: [github.com/stardog-union/stardog-language-servers/tree/master/packages/turtle-language-server](https://github.com/stardog-union/stardog-language-servers/tree/master/packages/turtle-language-server) -16. **SPARQL**: [github.com/stardog-union/stardog-language-servers/tree/master/packages/sparql-language-server](https://github.com/stardog-union/stardog-language-servers/tree/master/packages/sparql-language-server) +16. **Common Workflow Language (CWL)**: Rabix/Benten -17. **Turtle**: [github.com/stardog-union/stardog-language-servers/tree/master/packages/turtle-language-server](https://github.com/stardog-union/stardog-language-servers/tree/master/packages/turtle-language-server) +17. **Smalltalk/Pharo**: [github.com/badetitou/Pharo-LanguageServer](https://github.com/badetitou/Pharo-LanguageServer) -18. **Common Workflow Language (CWL)**: Rabix/Benten +18. **DreamMaker**: [github.com/SpaceManiac/SpacemanDMM/tree/master/crates/dm-langserver](https://github.com/SpaceManiac/SpacemanDMM/tree/master/crates/dm-langserver) -19. **Smalltalk/Pharo**: [github.com/badetitou/Pharo-LanguageServer](https://github.com/badetitou/Pharo-LanguageServer) +19. **Grain**: [github.com/grain-lang/grain](https://github.com/grain-lang/grain) -20. **DreamMaker**: [github.com/SpaceManiac/SpacemanDMM/tree/master/crates/dm-langserver](https://github.com/SpaceManiac/SpacemanDMM/tree/master/crates/dm-langserver) +20. **V**: [github.com/vlang/v-analyzer](https://github.com/vlang/v-analyzer) -21. **Grain**: [github.com/grain-lang/grain](https://github.com/grain-lang/grain) +21. **TTCN-3**: [github.com/nokia/ntt](https://github.com/nokia/ntt) -22. **V**: [github.com/vlang/v-analyzer](https://github.com/vlang/v-analyzer) +22. **Red**: [github.com/bitbegin/redlangserver](https://github.com/bitbegin/redlangserver) -23. **TTCN-3**: [github.com/nokia/ntt](https://github.com/nokia/ntt) +23. **Fennel**: [git.sr.ht/~xerool/fennel-ls](https://git.sr.ht/~xerool/fennel-ls) -24. **Red**: [github.com/bitbegin/redlangserver](https://github.com/bitbegin/redlangserver) +24. **Erg**: [github.com/erg-lang/erg/tree/main/crates/els](https://github.com/erg-lang/erg/tree/main/crates/els) -25. **Fennel**: [git.sr.ht/~xerool/fennel-ls](https://git.sr.ht/~xerool/fennel-ls) +25. **Fuzion**: [github.com/tokiwa-software/fuzion-lsp-server](https://github.com/tokiwa-software/fuzion-lsp-server) -26. **Erg**: [github.com/erg-lang/erg/tree/main/crates/els](https://github.com/erg-lang/erg/tree/main/crates/els) +26. **Imandra Protocol Language**: [github.com/AestheticIntegration/ipl-vscode](https://github.com/AestheticIntegration/ipl-vscode) -27. **Fuzion**: [github.com/tokiwa-software/fuzion-lsp-server](https://github.com/tokiwa-software/fuzion-lsp-server) +27. **MOCA**: [github.com/mrglassdanny/moca-language-server](https://github.com/mrglassdanny/moca-language-server) -28. **Imandra Protocol Language**: [github.com/AestheticIntegration/ipl-vscode](https://github.com/AestheticIntegration/ipl-vscode) +28. **openVALIDATION**: [github.com/openvalidation/ov-language-server](https://github.com/openvalidation/ov-language-server) -29. **MOCA**: [github.com/mrglassdanny/moca-language-server](https://github.com/mrglassdanny/moca-language-server) +29. **Veryl**: [github.com/dalance/veryl/tree/master/crates/languageserver](https://github.com/dalance/veryl/tree/master/crates/languageserver) -30. **openVALIDATION**: [github.com/openvalidation/ov-language-server](https://github.com/openvalidation/ov-language-server) +30. **Standard ML**: Millet -31. **Veryl**: [github.com/dalance/veryl/tree/master/crates/languageserver](https://github.com/dalance/veryl/tree/master/crates/languageserver) - -32. **Standard ML**: Millet - -33. **Systemtap**: Systemtap LSP +31. **Systemtap**: Systemtap LSP