├── .devcontainer ├── Dockerfile └── devcontainer.json ├── .github └── workflows │ ├── build.yml │ └── publish.yml ├── .gitignore ├── .gitmodules ├── .vscode ├── launch.json └── tasks.json ├── .vscodeignore ├── CHANGELOG.md ├── DEVELOPERS-README.md ├── LICENSE.md ├── README.md ├── client ├── package-lock.json ├── package.json ├── src │ ├── client.ts │ ├── debugger.ts │ └── extension.ts └── tsconfig.json ├── language-configuration.json ├── package-lock.json └── package.json /.devcontainer/Dockerfile: -------------------------------------------------------------------------------- 1 | FROM erlang:21 2 | 3 | RUN curl -sL https://deb.nodesource.com/setup_12.x | bash - 4 | 5 | RUN apt update && apt install -y \ 6 | git \ 7 | make \ 8 | nodejs \ 9 | && apt -y autoremove \ 10 | && apt -y clean \ 11 | && rm -rf /var/lib/apt/lists/* 12 | -------------------------------------------------------------------------------- /.devcontainer/devcontainer.json: -------------------------------------------------------------------------------- 1 | { 2 | "dockerFile": "Dockerfile", 3 | "extensions": [] 4 | } 5 | -------------------------------------------------------------------------------- /.github/workflows/build.yml: -------------------------------------------------------------------------------- 1 | name: Build 2 | on: 3 | push: 4 | branches: 5 | - '*' 6 | pull_request: 7 | types: 8 | - opened 9 | - synchronize 10 | jobs: 11 | build: 12 | runs-on: ubuntu-latest 13 | steps: 14 | - name: Checkout 15 | uses: actions/checkout@v2 16 | - name: Checkout submodules 17 | run: git submodule update --init --recursive 18 | - name: Install Node.js 19 | uses: actions/setup-node@v2 20 | with: 21 | node-version: '20' 22 | - name: Setup Erlang 23 | uses: erlef/setup-beam@v1 24 | with: 25 | otp-version: 24 26 | rebar3-version: 3.22.0 27 | - name: Show NPM version 28 | run: npm --version 29 | - run: npm install 30 | - run: npm run compile 31 | - name: Install VSCE 32 | run: npm install -g vsce 33 | - name: Package 34 | run: vsce package 35 | - name: Upload Artifacts 36 | uses: actions/upload-artifact@v4 37 | with: 38 | name: erlang-ls.vsix 39 | path: erlang-ls-*.vsix 40 | -------------------------------------------------------------------------------- /.github/workflows/publish.yml: -------------------------------------------------------------------------------- 1 | name: Publish 2 | on: 3 | release: 4 | types: [published] 5 | jobs: 6 | build: 7 | runs-on: ubuntu-latest 8 | steps: 9 | - name: Checkout 10 | uses: actions/checkout@v2 11 | - name: Checkout submodules 12 | run: git submodule update --init --recursive 13 | - name: Install Node.js 14 | uses: actions/setup-node@v2 15 | with: 16 | node-version: '20' 17 | - name: Setup Erlang 18 | uses: erlef/setup-beam@v1 19 | with: 20 | otp-version: 24 21 | rebar3-version: 3.22.0 22 | - name: Show NPM version 23 | run: npm --version 24 | - run: npm install 25 | - run: npm run compile 26 | - name: Install VSCE 27 | run: npm install -g vsce 28 | - name: Package 29 | run: vsce package 30 | - name: Upload Artifacts 31 | uses: actions/upload-artifact@v4 32 | with: 33 | name: erlang-ls.vsix 34 | path: erlang-ls-*.vsix 35 | - name: Publish extension to marketplace 36 | run: vsce publish -p ${{ secrets.VSCE_PAT }} 37 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | node_modules/ 2 | out/ 3 | *.vsix 4 | .tool-versions 5 | -------------------------------------------------------------------------------- /.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "erlang_ls"] 2 | path = erlang_ls 3 | url = https://github.com/erlang-ls/erlang_ls.git 4 | [submodule "grammar"] 5 | path = grammar 6 | url = https://github.com/erlang-ls/grammar.git 7 | [submodule "els_dap"] 8 | path = els_dap 9 | url = https://github.com/erlang-ls/els_dap.git 10 | -------------------------------------------------------------------------------- /.vscode/launch.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "0.2.0", 3 | "configurations": [ 4 | { 5 | "type": "extensionHost", 6 | "request": "launch", 7 | "name": "Launch Client", 8 | "runtimeExecutable": "${execPath}", 9 | "args": [ 10 | "--extensionDevelopmentPath=${workspaceRoot}" 11 | ], 12 | "outFiles": [ 13 | "${workspaceRoot}/client/out/**/*.js" 14 | ], 15 | "preLaunchTask": { 16 | "type": "npm", 17 | "script": "watch" 18 | } 19 | } 20 | ] 21 | } 22 | -------------------------------------------------------------------------------- /.vscode/tasks.json: -------------------------------------------------------------------------------- 1 | { 2 | "version": "2.0.0", 3 | "tasks": [ 4 | { 5 | "type": "npm", 6 | "script": "compile", 7 | "group": "build", 8 | "presentation": { 9 | "panel": "dedicated", 10 | "reveal": "never" 11 | }, 12 | "problemMatcher": [ 13 | "$tsc" 14 | ] 15 | }, 16 | { 17 | "type": "npm", 18 | "script": "watch", 19 | "isBackground": true, 20 | "group": { 21 | "kind": "build", 22 | "isDefault": true 23 | }, 24 | "presentation": { 25 | "panel": "dedicated", 26 | "reveal": "never" 27 | }, 28 | "problemMatcher": [ 29 | "$tsc-watch" 30 | ] 31 | } 32 | ] 33 | } 34 | -------------------------------------------------------------------------------- /.vscodeignore: -------------------------------------------------------------------------------- 1 | erlang_ls 2 | !erlang_ls/_build/*/bin/erlang_ls 3 | !erlang_ls/images/erlang-ls-logo-small.png 4 | !els_dap/_build/*/bin/els_dap 5 | 6 | .vscode/** 7 | **/*.ts 8 | **/*.map 9 | .gitignore 10 | **/tsconfig.json 11 | **/tsconfig.base.json 12 | contributing.md 13 | .travis.yml 14 | client/node_modules/** 15 | !client/node_modules/vscode-jsonrpc/** 16 | !client/node_modules/vscode-languageclient/** 17 | !client/node_modules/vscode-languageserver-protocol/** 18 | !client/node_modules/vscode-languageserver-types/** 19 | !client/node_modules/semver/** 20 | !client/node_modules/{minimatch,brace-expansion,concat-map,balanced-match}/** 21 | !client/node_modules/{semver,lru-cache,yallist}/** -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | ## Changelog 2 | 3 | ### 0.0.46 4 | 5 | Server (1.0.0 -> 1.1.0) 6 | 7 | - https://github.com/erlang-ls/erlang_ls/releases/tag/1.1.0 8 | 9 | ### 0.0.45 10 | 11 | Server (0.53.0 -> 1.0.0) 12 | 13 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.54.0 14 | - https://github.com/erlang-ls/erlang_ls/releases/tag/1.0.0 15 | 16 | ### 0.0.44 17 | 18 | Bump OTP version to 24 19 | Add custom escript runner configuration option 20 | 21 | Server (0.52.0 -> 0.53.0) 22 | 23 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.52.0 24 | 25 | ### 0.0.43 26 | 27 | Server (0.50.0 -> 0.52.0) 28 | 29 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.51.0 30 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.52.0 31 | 32 | ### 0.0.42 33 | 34 | Server (0.49.0 -> 0.50.0) 35 | 36 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.50.0 37 | 38 | ### 0.0.41 39 | 40 | Server (0.48.0 -> 0.49.0) 41 | 42 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.49.0 43 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.48.1 44 | 45 | Debugger (0.1.1 -> 0.1.2) 46 | 47 | - https://github.com/erlang-ls/els_dap/releases/tag/0.1.2 48 | 49 | ### 0.0.40 50 | 51 | Server (0.44.1 -> 0.48.0) 52 | 53 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.48.0 54 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.47.1 55 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.47.0 56 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.46.2 57 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.46.1 58 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.46.0 59 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.45.0 60 | 61 | ### 0.0.39 62 | 63 | Server (0.44.0 -> 0.44.1) 64 | 65 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.44.1 66 | 67 | ### 0.0.38 68 | 69 | Server (0.43.0 -> 0.44.0) 70 | 71 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.44.0 72 | 73 | ### 0.0.37 74 | 75 | Server (0.41.2 -> 0.43.0) 76 | 77 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.43.0 78 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.42.0 79 | 80 | ### 0.0.36 81 | 82 | Server (0.37.0 -> 0.41.2) 83 | 84 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.41.2 85 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.41.1 86 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.41.0 87 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.40.0 88 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.39.0 89 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.38.0 90 | 91 | ### 0.0.35 92 | 93 | Server (0.30.0 -> 0.37.0): 94 | 95 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.37.0 96 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.36.0 97 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.35.0 98 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.34.0 99 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.33.0 100 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.32.0 101 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.31.0 102 | 103 | ### 0.0.34 104 | 105 | Server (0.29.0 -> 0.30.0): 106 | 107 | - Ensure EPMD is running when launching debugger by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1276 108 | - Refactor folding_ranges onto POIs, Add support for records. by @tks2103 in https://github.com/erlang-ls/erlang_ls/pull/1268 109 | - Support for adding undefined Function by @f2000357 in https://github.com/erlang-ls/erlang_ls/pull/1267 110 | - Document versioning by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1265 111 | - Do not reload file from disk on save by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1278 112 | - Use version from didOpen, use text from editor as source of truth by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1279 113 | 114 | https://github.com/erlang-ls/erlang_ls/releases/tag/0.30.0 115 | 116 | ### 0.0.33 117 | 118 | Server (0.21.2 -> 0.29.0): 119 | 120 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.29.0 121 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.28.0 122 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.27.0 123 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.26.0 124 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.25.0 125 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.24.0 126 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.23.1 127 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.23.0 128 | - https://github.com/erlang-ls/erlang_ls/releases/tag/0.22.0 129 | 130 | ### 0.0.32 131 | 132 | Server (0.21.1 -> 0.21.2): 133 | 134 | - Revert unicode support by @garazdawi in https://github.com/erlang-ls/erlang_ls/pull/1151 135 | 136 | ### 0.0.31 137 | 138 | Server (0.20.0 -> 0.21.1): 139 | 140 | - Ignore test data directories by @dgud in https://github.com/erlang-ls/erlang_ls/pull/1109 141 | - Discover test files automatically by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1111 142 | - Hover docs for fun expressions referring to local or remote functions by @gomoripeti in https://github.com/erlang-ls/erlang_ls/pull/1112 143 | - Update erlfmt to 1.0.0 by @gomoripeti in https://github.com/erlang-ls/erlang_ls/pull/1113 144 | - Add make target `clean` by @JimMoen in https://github.com/erlang-ls/erlang_ls/pull/1116 145 | - Provide a Gradualizer diagnostic by @erszcz in https://github.com/erlang-ls/erlang_ls/pull/1117 146 | - Eep 48 markdown by @garazdawi in https://github.com/erlang-ls/erlang_ls/pull/1100 147 | - Remove fragile heuristics from editable_range by @gomoripeti in https://github.com/erlang-ls/erlang_ls/pull/1126 148 | - Do not recurse in els_utils:fold_files by @dgud in https://github.com/erlang-ls/erlang_ls/pull/1122 149 | - Refactor test framework for diagnostics by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1129 150 | - Bring back `coveralls send` step in CI by @pablocostass in https://github.com/erlang-ls/erlang_ls/pull/1130 151 | - Remove TCP support by @adrianroe in https://github.com/erlang-ls/erlang_ls/pull/1131 152 | - Do not include error description in code by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1141 153 | - Lower docs log message level to DEBUG by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1144 154 | - Fix unicode output via stdout by @garazdawi in https://github.com/erlang-ls/erlang_ls/pull/1147 155 | - [#1149] Exit with 0 on --version by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1150 156 | 157 | Extension: 158 | 159 | - Show server stdout in case of starting error by @robertoaloi in https://github.com/erlang-ls/vscode/pull/114 160 | 161 | ### 0.0.30 162 | 163 | Server (0.19.0 -> 0.20.0): 164 | 165 | - Fix DAP not finding the source for a module by @maxno-kivra in https://github.com/erlang-ls/erlang_ls/pull/1084 166 | - Temporarily skip coveralls send by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1087 167 | - Mark headers with compiler attributes as used by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1085 168 | - Handle Elvis config errors by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1088 169 | - User background job for hover provider to avoid blocking request queue by @TheGeorge in https://github.com/erlang-ls/erlang_ls/pull/1091 170 | - Add support for Call Hierarchy by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1096 171 | - Detect unused record fields by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1099 172 | - Shutdown request does not include parameters by @robertoaloi in https://github.com/erlang-ls/erlang_ls/pull/1108 173 | 174 | Extension: 175 | 176 | - Remove keywords from brackets (thanks @DOBRO) 177 | - Add support for LSP 3.16 (bump vscode-languageclient to 7.0.0) 178 | 179 | ### 0.0.29 180 | 181 | Server (0.18.0 -> 0.19.0): 182 | 183 | - Add config option to exclude unused headers from warnings (thanks @NAR) 184 | - Introduce experimental BSP support (thanks @al-khanji) 185 | - Find non-parametrized macro definitions (thanks @NAR) 186 | - Fix type mismatch in unused_macros diagnostic (thanks @nwalker) 187 | - Enable incremental_sync by default 188 | - Introduce diagnostic codes for the OTP compiler (thanks @alanz) 189 | - Simplify protocol implementation (thanks @al-khanji) 190 | - Add telemetry/event notifications for compiler diagnostics (thanks @alanz) 191 | 192 | Extension: 193 | 194 | - Recognize keywords as brackets (`if...end`, `begin...end`, etc) (thanks @ztion) 195 | - Add `use_long_names` configuration option (thanks @zsoci) 196 | 197 | ### 0.0.28 198 | 199 | Server (0.17.0 -> 0.18.0): 200 | 201 | - Fix issue with code reloading when no cookie is set up 202 | - Fix support for multiple threads in DAP continue request (thanks @TheGeorge) 203 | - Add guidelines on encoding binaries 204 | - Publish escripts as part of CI 205 | - Specify category for DAP events, so they get displayed via the Emacs UI 206 | - Speed up detection of unused includes (thanks @keynslug) 207 | - Fix issue with the initialization of the DAP server 208 | - Fix display of DAP logpoints 209 | - Show warning in case of missing configuration file 210 | - Reduce log level of events related to background jobs and compilation 211 | - Support macros as record names 212 | - Ignore Emacs backup and temporary files (thanks @pierre-rouleau) 213 | - Refactor distribution and improve support for longnames (thanks @zsoci) 214 | - Fix crash when applying edits to unicode text (thanks @plux) 215 | - Add hover support on record expressions (thanks @ztion) 216 | 217 | Grammar: 218 | 219 | - Comma is not needed in '-define' on the same line as macro name (thanks @danielfinke) 220 | - Allow comment between '}' and ').' in record definitions (thanks @KornelH) 221 | - Allow variables as module or function names in implicit function expressions (thanks @KornelH) 222 | - Distinguish function type in type specification and explicit function expression (thanks @KornelH) 223 | - Assign file extensions to Erlang mode: escript, yrl, xrl (thanks @KornelH) 224 | - '$' is a valid ASCII number (thanks @KornelH) 225 | - Escape sequences '^a'..'^z' are valid (and same as '^A'..'^Z') (thanks @KornelH) 226 | - Escape sequences '\xXY' (where XY are hexadecimal digits) are valid (thanks @KornelH) 227 | - 'utf8', 'utf16' and 'utf32' are valid type specifiers in binary (thanks @KornelH) 228 | - Binary unit type specifier has a mandatory parameters as 'unit:' (where is in range 1..256) (thanks @KornelH) 229 | - Single underscore (_) can be inserted between digits as a visual separator (since OTP 23) (thanks @KornelH) 230 | - Highlight 'true', 'false' and 'undefined' language constants. Well, technically 'undefined' is not that but traditionally used like that. (thanks @KornelH) 231 | 232 | ### 0.0.27 233 | 234 | Server (0.16.0 -> 0.17.0): 235 | 236 | - Prevent infinite recursion when enumerating document POIs (thanks @keynslug) 237 | - Fix creating macro POIs in function applications (thanks @gomoripeti) 238 | - Add logging via window/LogMessage (thanks @TheGeorge) 239 | - Find implementations for callback functions 240 | - Fix completion for incomplete export entry (thanks @gomoripete) 241 | - Fix docs for macros with arguments (thanks @gomoripeti) 242 | - Add support for renaming types (thanks @plux) 243 | - Add support for long names in DAP (thanks @zsoci) 244 | - Implement dummy handler for pause in DAP (thanks @TheGeorge) 245 | - Remove TCP support 246 | - Add support for attach in DAP (thanks @RunyaoZhang) 247 | 248 | ### 0.0.26 249 | 250 | Extension: 251 | 252 | - Fix debugger executable override path (thanks @RunyaoZhang) 253 | - Execute debugger via `escript` to ensure it works on Windows (thanks @misaki214) 254 | 255 | Server (0.15.0 -> 0.16.0): 256 | 257 | - Support renaming for record names and record fields (thanks @gomoripeti) 258 | - Correctly decode path to custom configuration on Windows (thanks @misaki214) 259 | - Allow config file to be named erlang_ls.yaml in addition to erlang_ls.config (thanks @elbrujohalcon) 260 | - Implement support for incremental text synchronization (thanks @plux) 261 | - Fix finding references for types defined in header files (thanks @plux) 262 | - Upgrade ranch dependency to 2.0.0 (thanks @plux) 263 | - Fix scoping for macro and record referencing (thanks @gomoripeti) 264 | - Use column numbers for Dialyzer diagnostics when available (thanks @plux) 265 | - Fix Dialyzer diagnostics support for OTP 24 (thanks @plux) 266 | - Truncate suggested spec titles (thanks @hellmean) 267 | - Improve installation instructions (thanks @pierre-rouleau) 268 | - Allow renaming functions when pointing at function references (thanks @plux) 269 | - Fix crash in function references code lens (thanks @hellmean) 270 | - Debugger support for conditions and hitconditions for breakpoints and logpoints (thanks @hajduakos) 271 | - Use erlfmt for parsing (thanks @gomoripeti) 272 | 273 | ### 0.0.25 274 | 275 | Extension: 276 | 277 | - Add support for debugger (thanks @TheGeorge) 278 | 279 | Server (0.14.0 -> 0.15.0): 280 | 281 | - Return references if no definitions are found (thanks @TheGeorge) 282 | - Fix incorrect bound variable warnings in fun expression heads (thanks @gomoripeti) 283 | - Clear stalled indicator on termination (thanks @zsoci) 284 | 285 | ### 0.0.24 286 | 287 | Server (0.13.0 -> 0.14.0): 288 | 289 | - Add support for renaming variables (thanks @plux) 290 | - Add support for renaming functions(thanks @plux) 291 | - Fix invalid crossref warnings for remote calls to module_info/0,1 (thanks @plux) 292 | - Supply completions for POIs in includes recursively (thanks @plux) 293 | - Add support for OTP 24 (thanks @garazdawi) 294 | - Show column numbers in compiler warnings (OTP 24+) (thanks @garazdawi) 295 | - More robust go-to definition in case of overlapping POIs (thanks @plux) 296 | - Add completion support for module attributes (thanks @plux) 297 | - Add context-based support for behaviour, include and include_lib (thanks @plux) 298 | - Show macro definitions on hover (thanks @plux) 299 | - Jump to definition from export_type entries (thanks @plux) 300 | - Cancel requests asynchronously 301 | 302 | ### 0.0.23 303 | 304 | Server (0.12.0 -> 0.13.0): 305 | 306 | - Fix config file used by PropEr tests (thanks @pablocostass) 307 | - Self-describing specs 308 | - New code lens (named function-references) to show references to a function 309 | - Optimize indexing (~4x speedup) (thanks @seriyps) 310 | - Add support for cancelling requests 311 | - Honour $/cancelRequest in the suggest-specs code lens 312 | - Limit completion to unexported functions when in an -export (thanks @plux) 313 | - Jump to variable definition (thanks @plux) 314 | - Fix linting issues (thanks @plux) 315 | 316 | ### 0.0.22 317 | 318 | Extension: 319 | 320 | - Bump outdated dependencies (thanks to @maxno-kivra) 321 | 322 | Server (0.11.0 -> 0.12.0): 323 | 324 | - Compress document ETS table, reducing RAM consumption (thanks @seriyps) 325 | - Fix support for snippets 326 | - Fix Elvis configuration and address linting issues 327 | - Remove dependency on cowlib, reducing size of the escript and 328 | compilation times 329 | - Enable `bound_var_in_pattern`, `unused_includes` and `unused_macros` 330 | diagnostics by default 331 | 332 | ### 0.0.21 333 | 334 | Extension: 335 | 336 | - Add basic indentation rules 337 | - Add closing pairs for quotes, single quotes and binaries 338 | 339 | ### 0.0.20 340 | 341 | Server (0.10.0 -> 0.11.0): 342 | 343 | - Jump to definition for non fully-qualified BIFs (thanks @al-khanji) 344 | - Implement `completionItem/resolve` 345 | - Fix extraction of spec when showing docs (thanks @gomoripeti) 346 | - Handle unicode when pretty printing function clauses (thanks @gomoripeti) 347 | - Make DAP connection to the node hidden (thanks @TheGeorge) 348 | - Ensure files are indexed when accessed for the first time (thanks @sgillis) 349 | - Add support for logpoints and fix the watchlist in DAP (thanks @TheGeorge) 350 | 351 | ### 0.0.19 352 | 353 | Grammar: 354 | 355 | - Fix support for ~ 356 | 357 | Server (0.9.0 -> 0.10.0): 358 | 359 | - Detect unused macros 360 | - Migrate from lager to OTP logger 361 | - Highlight already bound variables in patterns (thanks @gomoripeti) 362 | - Reduce memory consumption for POIs up to 80% (thanks @gomoripeti) 363 | - Improve DAP support (thanks @TheGeorge) 364 | - Experimental support for formatting code via the BSP protocol 365 | - Find references from all function clauses (thanks @gomoripeti) 366 | - Add Windows CI 367 | - Improve POI detection in attributes (thanks @gomoripeti) 368 | - Fix OTP 24 compiler warnings (thanks @garazdawi) 369 | - Handle macros in type attributes (thanks @gomoripeti) 370 | - Converted project to umbrella app (thanks @TheGeorge) 371 | - Fix support for quoted atoms (thanks @keynslug) 372 | 373 | ### 0.0.18 374 | 375 | Server (0.8.0 -> 0.9.0): 376 | 377 | - Support jumping from record field to record definition (thanks to @gomoripeti) 378 | - Allow usage of long names for the runtime node (thanks to @zsoci) 379 | - Fix macro renaming, where one extra character was deleted (thanks to @gomoripeti) 380 | - Build Dialyzer Persistent Lookup Table (plt) as part of make ci (thanks to @alanz) 381 | 382 | ### 0.0.17 383 | 384 | Extension: 385 | 386 | - Fork grammar used for Syntax Highlighting 387 | - Move CHANGELOG to separate file 388 | - Remove references to `debug` profile 389 | 390 | Server: 391 | 392 | - Suggest type specifications via TypEr 393 | - Jump to definition for parse transforms 394 | - Show OTP version on startup 395 | - Take into account parse transforms runtime dependencies 396 | - Silence Elvis during tests 397 | - Don't crash if compiler options are not found (thanks to @zsoci) 398 | - Handle macros in patterns (thanks to @gomoripeti) 399 | - Be able to add directories to code path via the code_path_extra_dirs config parameter (thanks to @zsoci) 400 | - Remove leftovers of db_dir (thanks to @gomoripeti) 401 | - Be able to define a custom path for the elvis.config file via the elvis_config_path config parameter (thanks to @define-null) 402 | 403 | ### 0.0.16 404 | 405 | Server: 406 | 407 | - Add support for [snippets](https://erlang-ls.github.io/articles/snippets-are-here/) 408 | - Fix a number of bugs related to POI ranges (thanks to @garazdawi) 409 | - Complete with arity only when dealing with a remote fun 410 | - Complete facelift for docs on hover 411 | - Include function clauses on hover 412 | - Refactor docs handling into separate module 413 | - Separate docs fetching from formatting 414 | - Refactor test code for hover into separate modules 415 | - Introduce symbol highlighting 416 | - More robust els_code_navigation:find_in_document/5 (thanks to @alanz) 417 | - Add support for renaming macros and callback functions 418 | - Be able to navigate to record definitions from types (thanks to @onno-vos-dev ) 419 | - Include project name in Erlang LS node names 420 | - Add support for code navigation for record definitions from type specs 421 | - Rename "xref" diagnostics to "crossref" (since they don't use XRef) 422 | - Add support for unused include files detection 423 | - Do not report crossref diagnostics for known pseudo-functions 424 | - Make docs chunk search use Erlang LS DB rather than code path 425 | - Remove dependency on Mnesia, use ETS only 426 | 427 | ### 0.0.15 428 | 429 | Server: 430 | 431 | - Do not crash while fetching docs due to missing encoding 432 | - Fix support for OTP 23 in CI 433 | - Remove obsolete `company-lsp` instructions 434 | - Pass custom macros to Dialyzer 435 | - Assume `COMPLETION_TRIGGER_KIND_INVOKED` when no context is provided 436 | - Do not ask for _text_ on save 437 | - Include experimental support for _DAP_ protocol 438 | - Add loop detection into dependency discovery 439 | - Fix path to PLT cache in CI 440 | - Handle `epp` error messages as diagnostics for included files 441 | - Remove spurious call to `els_dt_document:lookup/1` 442 | - Provide `serverInfo` in `initialize` response 443 | - Include OTP path to `server-info` lens to ease troubleshooting 444 | - Add support for `COMPLETION_TRIGGER_KIND_FOR_INCOMPLETE_COMPLETIONS` 445 | 446 | ### 0.0.14 447 | 448 | Server: 449 | 450 | - Do not attempt to load dependencies from sticky directories 451 | - Fix crash from asking erl_lint format our own error messages 452 | 453 | ### 0.0.13 454 | 455 | This release is equivalent to `0.0.12`, but built using OTP 21, to avoid issues for old OTP users 456 | 457 | ### 0.0.12 458 | 459 | Extension: 460 | 461 | - Link documentation from README 462 | - Fix security alert for minimalist dependency 463 | - Add missing repository property to avoid warning 464 | - Bump VSCode dependencies 465 | - Ignore files according to the lsp-sample extension 466 | - Bump erlang_ls to 0.4.0 467 | 468 | Server: 469 | 470 | - Add support for OTP 23 471 | - Fix support for OTP Doc Chunks 472 | - Show diagnostics for module dependencies 473 | - Use correct compilation options when reloading module dependencies 474 | - Do not crash when fetching docs for escriptized modules 475 | - Do not crash if root path contains spaces 476 | - Introduce log message when starting a new session 477 | - Add experimental XREF diagnostics (disabled by default) 478 | - Fix bug which caused a server crash when a notification contained a tilde (~) 479 | - When multiple instances of the same module are indexed, sort them deterministically 480 | - Fix various issues affecting Windows users 481 | - Allow underscore macros 482 | - Introduce experimental runtime node 483 | - Introduce experimental code lens for running CT tests (disabled by default) 484 | - New logo \o/ 485 | - Fix support for parse transforms 486 | - Include module name in progress reports for diagnostics 487 | - Wait for tables asynchronously 488 | - Add support for unbound progress reports 489 | - Show progress progress during DB initialization 490 | - Be able to jump to definition from a module import 491 | - Switch to stdio as the default transport 492 | - Be able to enable/disable code lenses and diagnostics 493 | - Do not consider all functions from the erlang module as BIFs 494 | - Remove deprecated port option from escript 495 | - Introduce general provider 496 | - Add code lens to show behaviour usages 497 | - Fix race condition where a server-initiated request was occasionally seen as a response 498 | - Fix type mismatch between protocol and transport types 499 | - Precalculate type specs 500 | - Minor fixes and improvements 501 | 502 | ### 0.0.11 503 | 504 | Extension: 505 | 506 | - Include .escript among known file extensions 507 | 508 | Server: 509 | 510 | - Improve URI handling 511 | - Introduce support for code lenses 512 | - Introduce server-info code lense (disabled by default) 513 | - Fix some Windows incompatibilities 514 | - Avoid the entire server crashing in case of failing providers 515 | - Improve support for Unicode 516 | - Introduce background jobs 517 | - Show progress while indexing 518 | - Fix handling of empty RootUri (Sublime users should enjoy this) 519 | - Add support for .escript files 520 | - Update logging framework 521 | - Add support for finding type references 522 | - Enable logging by default 523 | - Remove eflame dependency 524 | - Add auto-completion for built-in functions and types 525 | - Goto definition on an atom goes to that module if it exists 526 | - Fix symlinks handling 527 | - Add auto-completion for atoms 528 | - Add edoc support for OTP modules (requires OTP 23 once available) 529 | - Introduce CLI help menu via getopt 530 | 531 | ### 0.0.10 532 | 533 | Extension: 534 | 535 | - Configurable log level (default: none) 536 | - Configurable log path 537 | 538 | Server: 539 | 540 | - Add auto completion for types in `spec` and `export_types` contexts 541 | - Fix Elvis diagnostics for modules not belonging to the workspace 542 | - Fix off-by-one folding ranges for some editors 543 | - Restrict dependencies from accessing stdio, avoiding crashes on hover 544 | - Speed up indexing 545 | - Add syntax-highlighting for hover information 546 | - Fix inclusion path for dependencies 547 | - Show function information when hovering the `export` list 548 | - Add plumbing for code lenses 549 | - Find module references 550 | - Find macro references 551 | - Update code formatter to latest available version 552 | - Fix ranges for Dialyzer diagnostics 553 | - Avoid crash in presence of : within strings 554 | - Fix supervision strategy 555 | - Avoid un-necessary parsing 556 | - Asynchronous diagnostics 557 | 558 | ### 0.0.9 559 | 560 | Server: 561 | 562 | - Add support for behaviours diagnostics (compiler, dialyzer) 563 | - Add support for parse transform (compiler) 564 | - Find references for records 565 | - Fix support for `$/` notifications and requests 566 | - Be able to specify a different location for the `erlang_ls.config` file 567 | - Fix issue with Elvis diagnostics polluting stdio 568 | - Add root uri to start-up message 569 | - Fix include_dirs passed to Dialyzer 570 | - Inject exit message when TCP socket is closed 571 | - Add support for custom macros 572 | - Add support for hot-code reloading 573 | 574 | ### 0.0.8 575 | 576 | Extension: 577 | 578 | - Fix support for Windows 579 | - Add option to override the path to the language server 580 | 581 | ### 0.0.7 582 | 583 | Extension: 584 | 585 | - Add list of features to README 586 | - Enable debug mode 587 | 588 | ### 0.0.6 589 | 590 | Extension: 591 | 592 | - Bump vscode-languageclient to 6.0.0 593 | 594 | Server: 595 | 596 | - Add navigation to callback functions for OTP behaviours 597 | - Add support for folding ranges 598 | - Allow a system-wide erlang_ls.config file 599 | - Show edoc for local functions 600 | - Support cancel requests 601 | - Fix support for Dialyzer diagnostics 602 | - Show errors from included .hrl files 603 | - Correctly handle macros on record access 604 | - Remove dependency on wx 605 | - Use platform-dependent log directories 606 | - Automatically generate diagnostics when opening a file 607 | - Limit the amount of symbols returned as workspace symbols 608 | - Add plumbing for a formatter 609 | - Add support for umbrella projects 610 | - Add code completion for record fields 611 | - Use a persistent database (Mnesia) to store indexed information 612 | - Add support for Elvis diagnostics 613 | - Handle multiple export sections 614 | - Do not crash on un-handled extensions 615 | - Do not crash when macros are used as function names 616 | - Other bug fixes and stability improvements 617 | 618 | ### 0.0.5 619 | 620 | Extension: 621 | 622 | - Ignore TextMate folders that are not used by the extension 623 | - Add language configuration, including comments and brackets 624 | 625 | Server: 626 | 627 | - Report server version on startup 628 | - Fix ranges for compiler diagnostics 629 | - Fix completion of function/arity in export lists 630 | - Introduce document highlighting 631 | - Improve performance of workspace symbol lookups 632 | - Add completion for record names 633 | - Improve indexing performances 634 | - Properly cleanup outdated references 635 | - Other bug fixes and stability improvements 636 | 637 | ### 0.0.4 638 | 639 | Extension: 640 | 641 | - Do not include un-necessary files in the package, reducing the 642 | extension size from 20MB to 15MB 643 | 644 | ### 0.0.3 645 | 646 | Extension: 647 | 648 | - Add configuration option to enable tracing calls between client and server 649 | 650 | ### 0.0.2 651 | 652 | Server: 653 | 654 | - Performance improvements for the indexing process 655 | - Add code navigation for opaque types 656 | - Fix issue with non-unicode modules 657 | - Skip indexing of some OTP applications by default (diameter, megaco, snmp, wx) 658 | - Fix support for Markdown content on hover requests 659 | 660 | ### 0.0.1 661 | 662 | Initial version of the extension. 663 | -------------------------------------------------------------------------------- /DEVELOPERS-README.md: -------------------------------------------------------------------------------- 1 | # README for extension developers (Mac OS) 2 | 3 | ## Prerequisites 4 | 5 | * Install VSCode 6 | 7 | ``` 8 | npm install -g vsce 9 | npm install -g typescript 10 | ``` 11 | 12 | ## Quickstart 13 | 14 | ``` 15 | git submodule update --init 16 | rm -rf erlang_ls/_build 17 | rm -rf client/out 18 | npm install 19 | npm run compile 20 | vsce package 21 | ``` 22 | 23 | ## Publishing 24 | 25 | ``` 26 | vsce publish 27 | ``` 28 | 29 | ## Updating npm 30 | 31 | ``` 32 | npm install -g npm@latest 33 | ``` 34 | 35 | ## Updating dependencies 36 | 37 | Look for outdated packages: 38 | 39 | ``` 40 | npm outdated 41 | ``` 42 | 43 | Update the `package.json` 44 | 45 | ``` 46 | npm update 47 | ``` 48 | 49 | ## Handling Access Tokens 50 | 51 | https://code.visualstudio.com/api/working-with-extensions/publishing-extension 52 | 53 | ## Release Process 54 | 55 | ### Prepare the Release 56 | 57 | * Create a new branch 58 | * In the new branch, update the Erlang LS server. Enter the `erlang_ls` dir, then `git fetch; git checkout X.Y.Z` (where `X.Y.Z` is the version of Erlang LS you want to upgrade to 59 | * Repeat the same process for the other submodules (i.e. `grammar`, `els_dap`) if required 60 | * Open the `package.json` file and bump the `version` field 61 | * Run `npm install`. This will propagate the version bump to the `package-lock.json` file 62 | * Update the `CHANGELOG.md` file 63 | * Create a Pull Request with the above changes 64 | 65 | ### Verify the package 66 | 67 | * Once CI is completed for the above PR, download the `erlang-ls.vsix.zip` package from the build page 68 | * Unzip the package 69 | * Open VS Code, go to the Extension menu and click on "Install from VSIX" 70 | * Select the `erlang-ls.vsix` package you just downloaded 71 | * Open an Erlang file and ensure the extension works as expected 72 | * Merge the Pull Request 73 | 74 | ### Create a new release 75 | 76 | * Access the [releases](https://github.com/erlang-ls/vscode/releases) page 77 | * Click on "Draft a new release" 78 | * Click on the "Choose a tag" dropdown and enter a new tag (just increment, no semantic versioning) 79 | * Click on "Generate release notes" 80 | * Optionally amend the generated notes with highlights or other important information 81 | * Click on "Publish Release" 82 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | Apache License 2 | Version 2.0, January 2004 3 | http://www.apache.org/licenses/ 4 | 5 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION 6 | 7 | 1. Definitions. 8 | 9 | "License" shall mean the terms and conditions for use, reproduction, 10 | and distribution as defined by Sections 1 through 9 of this document. 11 | 12 | "Licensor" shall mean the copyright owner or entity authorized by 13 | the copyright owner that is granting the License. 14 | 15 | "Legal Entity" shall mean the union of the acting entity and all 16 | other entities that control, are controlled by, or are under common 17 | control with that entity. For the purposes of this definition, 18 | "control" means (i) the power, direct or indirect, to cause the 19 | direction or management of such entity, whether by contract or 20 | otherwise, or (ii) ownership of fifty percent (50%) or more of the 21 | outstanding shares, or (iii) beneficial ownership of such entity. 22 | 23 | "You" (or "Your") shall mean an individual or Legal Entity 24 | exercising permissions granted by this License. 25 | 26 | "Source" form shall mean the preferred form for making modifications, 27 | including but not limited to software source code, documentation 28 | source, and configuration files. 29 | 30 | "Object" form shall mean any form resulting from mechanical 31 | transformation or translation of a Source form, including but 32 | not limited to compiled object code, generated documentation, 33 | and conversions to other media types. 34 | 35 | "Work" shall mean the work of authorship, whether in Source or 36 | Object form, made available under the License, as indicated by a 37 | copyright notice that is included in or attached to the work 38 | (an example is provided in the Appendix below). 39 | 40 | "Derivative Works" shall mean any work, whether in Source or Object 41 | form, that is based on (or derived from) the Work and for which the 42 | editorial revisions, annotations, elaborations, or other modifications 43 | represent, as a whole, an original work of authorship. For the purposes 44 | of this License, Derivative Works shall not include works that remain 45 | separable from, or merely link (or bind by name) to the interfaces of, 46 | the Work and Derivative Works thereof. 47 | 48 | "Contribution" shall mean any work of authorship, including 49 | the original version of the Work and any modifications or additions 50 | to that Work or Derivative Works thereof, that is intentionally 51 | submitted to Licensor for inclusion in the Work by the copyright owner 52 | or by an individual or Legal Entity authorized to submit on behalf of 53 | the copyright owner. For the purposes of this definition, "submitted" 54 | means any form of electronic, verbal, or written communication sent 55 | to the Licensor or its representatives, including but not limited to 56 | communication on electronic mailing lists, source code control systems, 57 | and issue tracking systems that are managed by, or on behalf of, the 58 | Licensor for the purpose of discussing and improving the Work, but 59 | excluding communication that is conspicuously marked or otherwise 60 | designated in writing by the copyright owner as "Not a Contribution." 61 | 62 | "Contributor" shall mean Licensor and any individual or Legal Entity 63 | on behalf of whom a Contribution has been received by Licensor and 64 | subsequently incorporated within the Work. 65 | 66 | 2. Grant of Copyright License. Subject to the terms and conditions of 67 | this License, each Contributor hereby grants to You a perpetual, 68 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 69 | copyright license to reproduce, prepare Derivative Works of, 70 | publicly display, publicly perform, sublicense, and distribute the 71 | Work and such Derivative Works in Source or Object form. 72 | 73 | 3. Grant of Patent License. Subject to the terms and conditions of 74 | this License, each Contributor hereby grants to You a perpetual, 75 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable 76 | (except as stated in this section) patent license to make, have made, 77 | use, offer to sell, sell, import, and otherwise transfer the Work, 78 | where such license applies only to those patent claims licensable 79 | by such Contributor that are necessarily infringed by their 80 | Contribution(s) alone or by combination of their Contribution(s) 81 | with the Work to which such Contribution(s) was submitted. If You 82 | institute patent litigation against any entity (including a 83 | cross-claim or counterclaim in a lawsuit) alleging that the Work 84 | or a Contribution incorporated within the Work constitutes direct 85 | or contributory patent infringement, then any patent licenses 86 | granted to You under this License for that Work shall terminate 87 | as of the date such litigation is filed. 88 | 89 | 4. Redistribution. You may reproduce and distribute copies of the 90 | Work or Derivative Works thereof in any medium, with or without 91 | modifications, and in Source or Object form, provided that You 92 | meet the following conditions: 93 | 94 | (a) You must give any other recipients of the Work or 95 | Derivative Works a copy of this License; and 96 | 97 | (b) You must cause any modified files to carry prominent notices 98 | stating that You changed the files; and 99 | 100 | (c) You must retain, in the Source form of any Derivative Works 101 | that You distribute, all copyright, patent, trademark, and 102 | attribution notices from the Source form of the Work, 103 | excluding those notices that do not pertain to any part of 104 | the Derivative Works; and 105 | 106 | (d) If the Work includes a "NOTICE" text file as part of its 107 | distribution, then any Derivative Works that You distribute must 108 | include a readable copy of the attribution notices contained 109 | within such NOTICE file, excluding those notices that do not 110 | pertain to any part of the Derivative Works, in at least one 111 | of the following places: within a NOTICE text file distributed 112 | as part of the Derivative Works; within the Source form or 113 | documentation, if provided along with the Derivative Works; or, 114 | within a display generated by the Derivative Works, if and 115 | wherever such third-party notices normally appear. The contents 116 | of the NOTICE file are for informational purposes only and 117 | do not modify the License. You may add Your own attribution 118 | notices within Derivative Works that You distribute, alongside 119 | or as an addendum to the NOTICE text from the Work, provided 120 | that such additional attribution notices cannot be construed 121 | as modifying the License. 122 | 123 | You may add Your own copyright statement to Your modifications and 124 | may provide additional or different license terms and conditions 125 | for use, reproduction, or distribution of Your modifications, or 126 | for any such Derivative Works as a whole, provided Your use, 127 | reproduction, and distribution of the Work otherwise complies with 128 | the conditions stated in this License. 129 | 130 | 5. Submission of Contributions. Unless You explicitly state otherwise, 131 | any Contribution intentionally submitted for inclusion in the Work 132 | by You to the Licensor shall be under the terms and conditions of 133 | this License, without any additional terms or conditions. 134 | Notwithstanding the above, nothing herein shall supersede or modify 135 | the terms of any separate license agreement you may have executed 136 | with Licensor regarding such Contributions. 137 | 138 | 6. Trademarks. This License does not grant permission to use the trade 139 | names, trademarks, service marks, or product names of the Licensor, 140 | except as required for reasonable and customary use in describing the 141 | origin of the Work and reproducing the content of the NOTICE file. 142 | 143 | 7. Disclaimer of Warranty. Unless required by applicable law or 144 | agreed to in writing, Licensor provides the Work (and each 145 | Contributor provides its Contributions) on an "AS IS" BASIS, 146 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or 147 | implied, including, without limitation, any warranties or conditions 148 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A 149 | PARTICULAR PURPOSE. You are solely responsible for determining the 150 | appropriateness of using or redistributing the Work and assume any 151 | risks associated with Your exercise of permissions under this License. 152 | 153 | 8. Limitation of Liability. In no event and under no legal theory, 154 | whether in tort (including negligence), contract, or otherwise, 155 | unless required by applicable law (such as deliberate and grossly 156 | negligent acts) or agreed to in writing, shall any Contributor be 157 | liable to You for damages, including any direct, indirect, special, 158 | incidental, or consequential damages of any character arising as a 159 | result of this License or out of the use or inability to use the 160 | Work (including but not limited to damages for loss of goodwill, 161 | work stoppage, computer failure or malfunction, or any and all 162 | other commercial damages or losses), even if such Contributor 163 | has been advised of the possibility of such damages. 164 | 165 | 9. Accepting Warranty or Additional Liability. While redistributing 166 | the Work or Derivative Works thereof, You may choose to offer, 167 | and charge a fee for, acceptance of support, warranty, indemnity, 168 | or other liability obligations and/or rights consistent with this 169 | License. However, in accepting such obligations, You may act only 170 | on Your own behalf and on Your sole responsibility, not on behalf 171 | of any other Contributor, and only if You agree to indemnify, 172 | defend, and hold each Contributor harmless for any liability 173 | incurred by, or claims asserted against, such Contributor by reason 174 | of your accepting any such warranty or additional liability. 175 | 176 | END OF TERMS AND CONDITIONS 177 | 178 | APPENDIX: How to apply the Apache License to your work. 179 | 180 | To apply the Apache License to your work, attach the following 181 | boilerplate notice, with the fields enclosed by brackets "[]" 182 | replaced with your own identifying information. (Don't include 183 | the brackets!) The text should be enclosed in the appropriate 184 | comment syntax for the file format. We also recommend that a 185 | file or class name and description of purpose be included on the 186 | same "printed page" as the copyright notice for easier 187 | identification within third-party archives. 188 | 189 | Copyright [yyyy] [name of copyright owner] 190 | 191 | Licensed under the Apache License, Version 2.0 (the "License"); 192 | you may not use this file except in compliance with the License. 193 | You may obtain a copy of the License at 194 | 195 | http://www.apache.org/licenses/LICENSE-2.0 196 | 197 | Unless required by applicable law or agreed to in writing, software 198 | distributed under the License is distributed on an "AS IS" BASIS, 199 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 200 | See the License for the specific language governing permissions and 201 | limitations under the License. 202 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # erlang-ls/vscode 2 | 3 | The [Erlang LS](https://github.com/erlang-ls/erlang_ls) extension for 4 | VSCode. The documentation for Erlang LS is available at: 5 | 6 | https://erlang-ls.github.io 7 | 8 | It is possible to customize the extension for a given project via an 9 | `erlang_ls.config` file. [Learn 10 | how](https://erlang-ls.github.io/configuration/). 11 | 12 | ## Available Features 13 | 14 | ### Code Completion 15 | 16 | Get context-aware code completions for function names, macros, 17 | records, variable names and more. 18 | 19 | ![Code Completion](https://github.com/erlang-ls/docs/raw/master/png/vscode/01-code-completion.png) 20 | 21 | ### Go To Definition 22 | 23 | Navigate to the definition of a function, macro, record or type. 24 | 25 | ### Go To Implementation for OTP Behaviours 26 | 27 | Hovering a `gen_server:start_link` call? Jump to the respective `init` 28 | function with a single keystroke. 29 | 30 | ### Signature Suggestions 31 | 32 | Never remember the order of the `lists:keytake/3` function? You are 33 | not alone. We got you covered. 34 | 35 | ### Compiler Diagnostics 36 | 37 | Display warnings and errors from the compiler inline. 38 | 39 | ![Compiler Diagnostics](https://github.com/erlang-ls/docs/raw/master/png/vscode/05-compiler-diagnostics.png) 40 | 41 | ### Dialyzer Diagnostics 42 | 43 | It has never been so easy to make Dialyzer happy. 44 | 45 | ### Elvis Diagnostics 46 | 47 | Display [Elvis](https://github.com/inaka/elvis) style suggestions 48 | inline. No more nit-picking comments from colleagues! 49 | 50 | ### Edoc 51 | 52 | Hover a local or remote function to see its `edoc`. You will miss this 53 | feature so much when edocs are not available that you will start 54 | writing them! 55 | 56 | ### Navigation for Included Files 57 | 58 | Navigate to included files with a single click. 59 | 60 | ### Find/Peek References 61 | 62 | Who is calling this function? Figure it out without leaving the 63 | current context. 64 | 65 | ![Peek References](https://github.com/erlang-ls/docs/raw/master/png/vscode/11-peek-references.png) 66 | 67 | ### Outline 68 | 69 | Get a nice outline of your module on the side and jump between 70 | functions. 71 | 72 | ![Outline](https://github.com/erlang-ls/docs/raw/master/png/vscode/12-outline.png) 73 | 74 | ### Workspace Symbols 75 | 76 | Jump to the module you're looking for, in no time. 77 | 78 | ### Folding 79 | 80 | Focus on what's important, fold the rest. 81 | -------------------------------------------------------------------------------- /client/package-lock.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "erlang-ls-client", 3 | "version": "0.0.1", 4 | "lockfileVersion": 2, 5 | "requires": true, 6 | "packages": { 7 | "": { 8 | "name": "erlang-ls-client", 9 | "version": "0.0.1", 10 | "license": "Apache-2.0", 11 | "dependencies": { 12 | "vscode-languageclient": "^7.0.0" 13 | }, 14 | "devDependencies": { 15 | "@types/vscode": "^1.60.0", 16 | "vscode-test": "^1.5.1" 17 | }, 18 | "engines": { 19 | "vscode": "^1.60.0" 20 | } 21 | }, 22 | "node_modules/@tootallnate/once": { 23 | "version": "1.1.2", 24 | "resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-1.1.2.tgz", 25 | "integrity": "sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==", 26 | "dev": true, 27 | "engines": { 28 | "node": ">= 6" 29 | } 30 | }, 31 | "node_modules/@types/vscode": { 32 | "version": "1.66.0", 33 | "resolved": "https://registry.npmjs.org/@types/vscode/-/vscode-1.66.0.tgz", 34 | "integrity": "sha512-ZfJck4M7nrGasfs4A4YbUoxis3Vu24cETw3DERsNYtDZmYSYtk6ljKexKFKhImO/ZmY6ZMsmegu2FPkXoUFImA==", 35 | "dev": true 36 | }, 37 | "node_modules/agent-base": { 38 | "version": "6.0.2", 39 | "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz", 40 | "integrity": "sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==", 41 | "dev": true, 42 | "dependencies": { 43 | "debug": "4" 44 | }, 45 | "engines": { 46 | "node": ">= 6.0.0" 47 | } 48 | }, 49 | "node_modules/balanced-match": { 50 | "version": "1.0.2", 51 | "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", 52 | "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" 53 | }, 54 | "node_modules/big-integer": { 55 | "version": "1.6.51", 56 | "resolved": "https://registry.npmjs.org/big-integer/-/big-integer-1.6.51.tgz", 57 | "integrity": "sha512-GPEid2Y9QU1Exl1rpO9B2IPJGHPSupF5GnVIP0blYvNOMer2bTvSWs1jGOUg04hTmu67nmLsQ9TBo1puaotBHg==", 58 | "dev": true, 59 | "engines": { 60 | "node": ">=0.6" 61 | } 62 | }, 63 | "node_modules/binary": { 64 | "version": "0.3.0", 65 | "resolved": "https://registry.npmjs.org/binary/-/binary-0.3.0.tgz", 66 | "integrity": "sha1-n2BVO8XOjDOG87VTz/R0Yq3sqnk=", 67 | "dev": true, 68 | "dependencies": { 69 | "buffers": "~0.1.1", 70 | "chainsaw": "~0.1.0" 71 | }, 72 | "engines": { 73 | "node": "*" 74 | } 75 | }, 76 | "node_modules/bluebird": { 77 | "version": "3.4.7", 78 | "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.4.7.tgz", 79 | "integrity": "sha1-9y12C+Cbf3bQjtj66Ysomo0F+rM=", 80 | "dev": true 81 | }, 82 | "node_modules/brace-expansion": { 83 | "version": "1.1.11", 84 | "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", 85 | "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", 86 | "dependencies": { 87 | "balanced-match": "^1.0.0", 88 | "concat-map": "0.0.1" 89 | } 90 | }, 91 | "node_modules/buffer-indexof-polyfill": { 92 | "version": "1.0.2", 93 | "resolved": "https://registry.npmjs.org/buffer-indexof-polyfill/-/buffer-indexof-polyfill-1.0.2.tgz", 94 | "integrity": "sha512-I7wzHwA3t1/lwXQh+A5PbNvJxgfo5r3xulgpYDB5zckTu/Z9oUK9biouBKQUjEqzaz3HnAT6TYoovmE+GqSf7A==", 95 | "dev": true, 96 | "engines": { 97 | "node": ">=0.10" 98 | } 99 | }, 100 | "node_modules/buffers": { 101 | "version": "0.1.1", 102 | "resolved": "https://registry.npmjs.org/buffers/-/buffers-0.1.1.tgz", 103 | "integrity": "sha1-skV5w77U1tOWru5tmorn9Ugqt7s=", 104 | "dev": true, 105 | "engines": { 106 | "node": ">=0.2.0" 107 | } 108 | }, 109 | "node_modules/chainsaw": { 110 | "version": "0.1.0", 111 | "resolved": "https://registry.npmjs.org/chainsaw/-/chainsaw-0.1.0.tgz", 112 | "integrity": "sha1-XqtQsor+WAdNDVgpE4iCi15fvJg=", 113 | "dev": true, 114 | "dependencies": { 115 | "traverse": ">=0.3.0 <0.4" 116 | }, 117 | "engines": { 118 | "node": "*" 119 | } 120 | }, 121 | "node_modules/concat-map": { 122 | "version": "0.0.1", 123 | "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", 124 | "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" 125 | }, 126 | "node_modules/core-util-is": { 127 | "version": "1.0.3", 128 | "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", 129 | "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", 130 | "dev": true 131 | }, 132 | "node_modules/debug": { 133 | "version": "4.3.4", 134 | "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", 135 | "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", 136 | "dev": true, 137 | "dependencies": { 138 | "ms": "2.1.2" 139 | }, 140 | "engines": { 141 | "node": ">=6.0" 142 | }, 143 | "peerDependenciesMeta": { 144 | "supports-color": { 145 | "optional": true 146 | } 147 | } 148 | }, 149 | "node_modules/duplexer2": { 150 | "version": "0.1.4", 151 | "resolved": "https://registry.npmjs.org/duplexer2/-/duplexer2-0.1.4.tgz", 152 | "integrity": "sha1-ixLauHjA1p4+eJEFFmKjL8a93ME=", 153 | "dev": true, 154 | "dependencies": { 155 | "readable-stream": "^2.0.2" 156 | } 157 | }, 158 | "node_modules/fs.realpath": { 159 | "version": "1.0.0", 160 | "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", 161 | "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", 162 | "dev": true 163 | }, 164 | "node_modules/fstream": { 165 | "version": "1.0.12", 166 | "resolved": "https://registry.npmjs.org/fstream/-/fstream-1.0.12.tgz", 167 | "integrity": "sha512-WvJ193OHa0GHPEL+AycEJgxvBEwyfRkN1vhjca23OaPVMCaLCXTd5qAu82AjTcgP1UJmytkOKb63Ypde7raDIg==", 168 | "dev": true, 169 | "dependencies": { 170 | "graceful-fs": "^4.1.2", 171 | "inherits": "~2.0.0", 172 | "mkdirp": ">=0.5 0", 173 | "rimraf": "2" 174 | }, 175 | "engines": { 176 | "node": ">=0.6" 177 | } 178 | }, 179 | "node_modules/fstream/node_modules/rimraf": { 180 | "version": "2.7.1", 181 | "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", 182 | "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", 183 | "dev": true, 184 | "dependencies": { 185 | "glob": "^7.1.3" 186 | }, 187 | "bin": { 188 | "rimraf": "bin.js" 189 | } 190 | }, 191 | "node_modules/glob": { 192 | "version": "7.2.0", 193 | "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", 194 | "integrity": "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==", 195 | "dev": true, 196 | "dependencies": { 197 | "fs.realpath": "^1.0.0", 198 | "inflight": "^1.0.4", 199 | "inherits": "2", 200 | "minimatch": "^3.0.4", 201 | "once": "^1.3.0", 202 | "path-is-absolute": "^1.0.0" 203 | }, 204 | "engines": { 205 | "node": "*" 206 | }, 207 | "funding": { 208 | "url": "https://github.com/sponsors/isaacs" 209 | } 210 | }, 211 | "node_modules/graceful-fs": { 212 | "version": "4.2.10", 213 | "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", 214 | "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", 215 | "dev": true 216 | }, 217 | "node_modules/http-proxy-agent": { 218 | "version": "4.0.1", 219 | "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-4.0.1.tgz", 220 | "integrity": "sha512-k0zdNgqWTGA6aeIRVpvfVob4fL52dTfaehylg0Y4UvSySvOq/Y+BOyPrgpUrA7HylqvU8vIZGsRuXmspskV0Tg==", 221 | "dev": true, 222 | "dependencies": { 223 | "@tootallnate/once": "1", 224 | "agent-base": "6", 225 | "debug": "4" 226 | }, 227 | "engines": { 228 | "node": ">= 6" 229 | } 230 | }, 231 | "node_modules/https-proxy-agent": { 232 | "version": "5.0.1", 233 | "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz", 234 | "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==", 235 | "dev": true, 236 | "dependencies": { 237 | "agent-base": "6", 238 | "debug": "4" 239 | }, 240 | "engines": { 241 | "node": ">= 6" 242 | } 243 | }, 244 | "node_modules/inflight": { 245 | "version": "1.0.6", 246 | "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", 247 | "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", 248 | "dev": true, 249 | "dependencies": { 250 | "once": "^1.3.0", 251 | "wrappy": "1" 252 | } 253 | }, 254 | "node_modules/inherits": { 255 | "version": "2.0.4", 256 | "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", 257 | "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", 258 | "dev": true 259 | }, 260 | "node_modules/isarray": { 261 | "version": "1.0.0", 262 | "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", 263 | "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", 264 | "dev": true 265 | }, 266 | "node_modules/listenercount": { 267 | "version": "1.0.1", 268 | "resolved": "https://registry.npmjs.org/listenercount/-/listenercount-1.0.1.tgz", 269 | "integrity": "sha1-hMinKrWcRyUyFIDJdeZQg0LnCTc=", 270 | "dev": true 271 | }, 272 | "node_modules/lru-cache": { 273 | "version": "6.0.0", 274 | "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", 275 | "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", 276 | "dependencies": { 277 | "yallist": "^4.0.0" 278 | }, 279 | "engines": { 280 | "node": ">=10" 281 | } 282 | }, 283 | "node_modules/minimatch": { 284 | "version": "3.1.2", 285 | "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", 286 | "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", 287 | "dependencies": { 288 | "brace-expansion": "^1.1.7" 289 | }, 290 | "engines": { 291 | "node": "*" 292 | } 293 | }, 294 | "node_modules/minimist": { 295 | "version": "1.2.6", 296 | "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz", 297 | "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==", 298 | "dev": true 299 | }, 300 | "node_modules/mkdirp": { 301 | "version": "0.5.6", 302 | "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.6.tgz", 303 | "integrity": "sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==", 304 | "dev": true, 305 | "dependencies": { 306 | "minimist": "^1.2.6" 307 | }, 308 | "bin": { 309 | "mkdirp": "bin/cmd.js" 310 | } 311 | }, 312 | "node_modules/ms": { 313 | "version": "2.1.2", 314 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", 315 | "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", 316 | "dev": true 317 | }, 318 | "node_modules/once": { 319 | "version": "1.4.0", 320 | "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", 321 | "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", 322 | "dev": true, 323 | "dependencies": { 324 | "wrappy": "1" 325 | } 326 | }, 327 | "node_modules/path-is-absolute": { 328 | "version": "1.0.1", 329 | "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", 330 | "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", 331 | "dev": true, 332 | "engines": { 333 | "node": ">=0.10.0" 334 | } 335 | }, 336 | "node_modules/process-nextick-args": { 337 | "version": "2.0.1", 338 | "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", 339 | "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", 340 | "dev": true 341 | }, 342 | "node_modules/readable-stream": { 343 | "version": "2.3.7", 344 | "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", 345 | "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", 346 | "dev": true, 347 | "dependencies": { 348 | "core-util-is": "~1.0.0", 349 | "inherits": "~2.0.3", 350 | "isarray": "~1.0.0", 351 | "process-nextick-args": "~2.0.0", 352 | "safe-buffer": "~5.1.1", 353 | "string_decoder": "~1.1.1", 354 | "util-deprecate": "~1.0.1" 355 | } 356 | }, 357 | "node_modules/rimraf": { 358 | "version": "3.0.2", 359 | "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", 360 | "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", 361 | "dev": true, 362 | "dependencies": { 363 | "glob": "^7.1.3" 364 | }, 365 | "bin": { 366 | "rimraf": "bin.js" 367 | }, 368 | "funding": { 369 | "url": "https://github.com/sponsors/isaacs" 370 | } 371 | }, 372 | "node_modules/safe-buffer": { 373 | "version": "5.1.2", 374 | "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", 375 | "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", 376 | "dev": true 377 | }, 378 | "node_modules/semver": { 379 | "version": "7.5.4", 380 | "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", 381 | "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", 382 | "dependencies": { 383 | "lru-cache": "^6.0.0" 384 | }, 385 | "bin": { 386 | "semver": "bin/semver.js" 387 | }, 388 | "engines": { 389 | "node": ">=10" 390 | } 391 | }, 392 | "node_modules/setimmediate": { 393 | "version": "1.0.5", 394 | "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", 395 | "integrity": "sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU=", 396 | "dev": true 397 | }, 398 | "node_modules/string_decoder": { 399 | "version": "1.1.1", 400 | "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", 401 | "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", 402 | "dev": true, 403 | "dependencies": { 404 | "safe-buffer": "~5.1.0" 405 | } 406 | }, 407 | "node_modules/traverse": { 408 | "version": "0.3.9", 409 | "resolved": "https://registry.npmjs.org/traverse/-/traverse-0.3.9.tgz", 410 | "integrity": "sha1-cXuPIgzAu3tE5AUUwisui7xw2Lk=", 411 | "dev": true, 412 | "engines": { 413 | "node": "*" 414 | } 415 | }, 416 | "node_modules/unzipper": { 417 | "version": "0.10.11", 418 | "resolved": "https://registry.npmjs.org/unzipper/-/unzipper-0.10.11.tgz", 419 | "integrity": "sha512-+BrAq2oFqWod5IESRjL3S8baohbevGcVA+teAIOYWM3pDVdseogqbzhhvvmiyQrUNKFUnDMtELW3X8ykbyDCJw==", 420 | "dev": true, 421 | "dependencies": { 422 | "big-integer": "^1.6.17", 423 | "binary": "~0.3.0", 424 | "bluebird": "~3.4.1", 425 | "buffer-indexof-polyfill": "~1.0.0", 426 | "duplexer2": "~0.1.4", 427 | "fstream": "^1.0.12", 428 | "graceful-fs": "^4.2.2", 429 | "listenercount": "~1.0.1", 430 | "readable-stream": "~2.3.6", 431 | "setimmediate": "~1.0.4" 432 | } 433 | }, 434 | "node_modules/util-deprecate": { 435 | "version": "1.0.2", 436 | "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", 437 | "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", 438 | "dev": true 439 | }, 440 | "node_modules/vscode-jsonrpc": { 441 | "version": "6.0.0", 442 | "resolved": "https://registry.npmjs.org/vscode-jsonrpc/-/vscode-jsonrpc-6.0.0.tgz", 443 | "integrity": "sha512-wnJA4BnEjOSyFMvjZdpiOwhSq9uDoK8e/kpRJDTaMYzwlkrhG1fwDIZI94CLsLzlCK5cIbMMtFlJlfR57Lavmg==", 444 | "engines": { 445 | "node": ">=8.0.0 || >=10.0.0" 446 | } 447 | }, 448 | "node_modules/vscode-languageclient": { 449 | "version": "7.0.0", 450 | "resolved": "https://registry.npmjs.org/vscode-languageclient/-/vscode-languageclient-7.0.0.tgz", 451 | "integrity": "sha512-P9AXdAPlsCgslpP9pRxYPqkNYV7Xq8300/aZDpO35j1fJm/ncize8iGswzYlcvFw5DQUx4eVk+KvfXdL0rehNg==", 452 | "dependencies": { 453 | "minimatch": "^3.0.4", 454 | "semver": "^7.3.4", 455 | "vscode-languageserver-protocol": "3.16.0" 456 | }, 457 | "engines": { 458 | "vscode": "^1.52.0" 459 | } 460 | }, 461 | "node_modules/vscode-languageserver-protocol": { 462 | "version": "3.16.0", 463 | "resolved": "https://registry.npmjs.org/vscode-languageserver-protocol/-/vscode-languageserver-protocol-3.16.0.tgz", 464 | "integrity": "sha512-sdeUoAawceQdgIfTI+sdcwkiK2KU+2cbEYA0agzM2uqaUy2UpnnGHtWTHVEtS0ES4zHU0eMFRGN+oQgDxlD66A==", 465 | "dependencies": { 466 | "vscode-jsonrpc": "6.0.0", 467 | "vscode-languageserver-types": "3.16.0" 468 | } 469 | }, 470 | "node_modules/vscode-languageserver-types": { 471 | "version": "3.16.0", 472 | "resolved": "https://registry.npmjs.org/vscode-languageserver-types/-/vscode-languageserver-types-3.16.0.tgz", 473 | "integrity": "sha512-k8luDIWJWyenLc5ToFQQMaSrqCHiLwyKPHKPQZ5zz21vM+vIVUSvsRpcbiECH4WR88K2XZqc4ScRcZ7nk/jbeA==" 474 | }, 475 | "node_modules/vscode-test": { 476 | "version": "1.6.1", 477 | "resolved": "https://registry.npmjs.org/vscode-test/-/vscode-test-1.6.1.tgz", 478 | "integrity": "sha512-086q88T2ca1k95mUzffvbzb7esqQNvJgiwY4h29ukPhFo8u+vXOOmelUoU5EQUHs3Of8+JuQ3oGdbVCqaxuTXA==", 479 | "deprecated": "This package has been renamed to @vscode/test-electron, please update to the new name", 480 | "dev": true, 481 | "dependencies": { 482 | "http-proxy-agent": "^4.0.1", 483 | "https-proxy-agent": "^5.0.0", 484 | "rimraf": "^3.0.2", 485 | "unzipper": "^0.10.11" 486 | }, 487 | "engines": { 488 | "node": ">=8.9.3" 489 | } 490 | }, 491 | "node_modules/wrappy": { 492 | "version": "1.0.2", 493 | "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", 494 | "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", 495 | "dev": true 496 | }, 497 | "node_modules/yallist": { 498 | "version": "4.0.0", 499 | "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", 500 | "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" 501 | } 502 | }, 503 | "dependencies": { 504 | "@tootallnate/once": { 505 | "version": "1.1.2", 506 | "resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-1.1.2.tgz", 507 | "integrity": "sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==", 508 | "dev": true 509 | }, 510 | "@types/vscode": { 511 | "version": "1.66.0", 512 | "resolved": "https://registry.npmjs.org/@types/vscode/-/vscode-1.66.0.tgz", 513 | "integrity": "sha512-ZfJck4M7nrGasfs4A4YbUoxis3Vu24cETw3DERsNYtDZmYSYtk6ljKexKFKhImO/ZmY6ZMsmegu2FPkXoUFImA==", 514 | "dev": true 515 | }, 516 | "agent-base": { 517 | "version": "6.0.2", 518 | "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz", 519 | "integrity": "sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==", 520 | "dev": true, 521 | "requires": { 522 | "debug": "4" 523 | } 524 | }, 525 | "balanced-match": { 526 | "version": "1.0.2", 527 | "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", 528 | "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" 529 | }, 530 | "big-integer": { 531 | "version": "1.6.51", 532 | "resolved": "https://registry.npmjs.org/big-integer/-/big-integer-1.6.51.tgz", 533 | "integrity": "sha512-GPEid2Y9QU1Exl1rpO9B2IPJGHPSupF5GnVIP0blYvNOMer2bTvSWs1jGOUg04hTmu67nmLsQ9TBo1puaotBHg==", 534 | "dev": true 535 | }, 536 | "binary": { 537 | "version": "0.3.0", 538 | "resolved": "https://registry.npmjs.org/binary/-/binary-0.3.0.tgz", 539 | "integrity": "sha1-n2BVO8XOjDOG87VTz/R0Yq3sqnk=", 540 | "dev": true, 541 | "requires": { 542 | "buffers": "~0.1.1", 543 | "chainsaw": "~0.1.0" 544 | } 545 | }, 546 | "bluebird": { 547 | "version": "3.4.7", 548 | "resolved": "https://registry.npmjs.org/bluebird/-/bluebird-3.4.7.tgz", 549 | "integrity": "sha1-9y12C+Cbf3bQjtj66Ysomo0F+rM=", 550 | "dev": true 551 | }, 552 | "brace-expansion": { 553 | "version": "1.1.11", 554 | "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", 555 | "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", 556 | "requires": { 557 | "balanced-match": "^1.0.0", 558 | "concat-map": "0.0.1" 559 | } 560 | }, 561 | "buffer-indexof-polyfill": { 562 | "version": "1.0.2", 563 | "resolved": "https://registry.npmjs.org/buffer-indexof-polyfill/-/buffer-indexof-polyfill-1.0.2.tgz", 564 | "integrity": "sha512-I7wzHwA3t1/lwXQh+A5PbNvJxgfo5r3xulgpYDB5zckTu/Z9oUK9biouBKQUjEqzaz3HnAT6TYoovmE+GqSf7A==", 565 | "dev": true 566 | }, 567 | "buffers": { 568 | "version": "0.1.1", 569 | "resolved": "https://registry.npmjs.org/buffers/-/buffers-0.1.1.tgz", 570 | "integrity": "sha1-skV5w77U1tOWru5tmorn9Ugqt7s=", 571 | "dev": true 572 | }, 573 | "chainsaw": { 574 | "version": "0.1.0", 575 | "resolved": "https://registry.npmjs.org/chainsaw/-/chainsaw-0.1.0.tgz", 576 | "integrity": "sha1-XqtQsor+WAdNDVgpE4iCi15fvJg=", 577 | "dev": true, 578 | "requires": { 579 | "traverse": ">=0.3.0 <0.4" 580 | } 581 | }, 582 | "concat-map": { 583 | "version": "0.0.1", 584 | "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", 585 | "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" 586 | }, 587 | "core-util-is": { 588 | "version": "1.0.3", 589 | "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", 590 | "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", 591 | "dev": true 592 | }, 593 | "debug": { 594 | "version": "4.3.4", 595 | "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", 596 | "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", 597 | "dev": true, 598 | "requires": { 599 | "ms": "2.1.2" 600 | } 601 | }, 602 | "duplexer2": { 603 | "version": "0.1.4", 604 | "resolved": "https://registry.npmjs.org/duplexer2/-/duplexer2-0.1.4.tgz", 605 | "integrity": "sha1-ixLauHjA1p4+eJEFFmKjL8a93ME=", 606 | "dev": true, 607 | "requires": { 608 | "readable-stream": "^2.0.2" 609 | } 610 | }, 611 | "fs.realpath": { 612 | "version": "1.0.0", 613 | "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", 614 | "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", 615 | "dev": true 616 | }, 617 | "fstream": { 618 | "version": "1.0.12", 619 | "resolved": "https://registry.npmjs.org/fstream/-/fstream-1.0.12.tgz", 620 | "integrity": "sha512-WvJ193OHa0GHPEL+AycEJgxvBEwyfRkN1vhjca23OaPVMCaLCXTd5qAu82AjTcgP1UJmytkOKb63Ypde7raDIg==", 621 | "dev": true, 622 | "requires": { 623 | "graceful-fs": "^4.1.2", 624 | "inherits": "~2.0.0", 625 | "mkdirp": ">=0.5 0", 626 | "rimraf": "2" 627 | }, 628 | "dependencies": { 629 | "rimraf": { 630 | "version": "2.7.1", 631 | "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-2.7.1.tgz", 632 | "integrity": "sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==", 633 | "dev": true, 634 | "requires": { 635 | "glob": "^7.1.3" 636 | } 637 | } 638 | } 639 | }, 640 | "glob": { 641 | "version": "7.2.0", 642 | "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", 643 | "integrity": "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==", 644 | "dev": true, 645 | "requires": { 646 | "fs.realpath": "^1.0.0", 647 | "inflight": "^1.0.4", 648 | "inherits": "2", 649 | "minimatch": "^3.0.4", 650 | "once": "^1.3.0", 651 | "path-is-absolute": "^1.0.0" 652 | } 653 | }, 654 | "graceful-fs": { 655 | "version": "4.2.10", 656 | "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.10.tgz", 657 | "integrity": "sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==", 658 | "dev": true 659 | }, 660 | "http-proxy-agent": { 661 | "version": "4.0.1", 662 | "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-4.0.1.tgz", 663 | "integrity": "sha512-k0zdNgqWTGA6aeIRVpvfVob4fL52dTfaehylg0Y4UvSySvOq/Y+BOyPrgpUrA7HylqvU8vIZGsRuXmspskV0Tg==", 664 | "dev": true, 665 | "requires": { 666 | "@tootallnate/once": "1", 667 | "agent-base": "6", 668 | "debug": "4" 669 | } 670 | }, 671 | "https-proxy-agent": { 672 | "version": "5.0.1", 673 | "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz", 674 | "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==", 675 | "dev": true, 676 | "requires": { 677 | "agent-base": "6", 678 | "debug": "4" 679 | } 680 | }, 681 | "inflight": { 682 | "version": "1.0.6", 683 | "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", 684 | "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", 685 | "dev": true, 686 | "requires": { 687 | "once": "^1.3.0", 688 | "wrappy": "1" 689 | } 690 | }, 691 | "inherits": { 692 | "version": "2.0.4", 693 | "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", 694 | "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", 695 | "dev": true 696 | }, 697 | "isarray": { 698 | "version": "1.0.0", 699 | "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", 700 | "integrity": "sha1-u5NdSFgsuhaMBoNJV6VKPgcSTxE=", 701 | "dev": true 702 | }, 703 | "listenercount": { 704 | "version": "1.0.1", 705 | "resolved": "https://registry.npmjs.org/listenercount/-/listenercount-1.0.1.tgz", 706 | "integrity": "sha1-hMinKrWcRyUyFIDJdeZQg0LnCTc=", 707 | "dev": true 708 | }, 709 | "lru-cache": { 710 | "version": "6.0.0", 711 | "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", 712 | "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", 713 | "requires": { 714 | "yallist": "^4.0.0" 715 | } 716 | }, 717 | "minimatch": { 718 | "version": "3.1.2", 719 | "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", 720 | "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", 721 | "requires": { 722 | "brace-expansion": "^1.1.7" 723 | } 724 | }, 725 | "minimist": { 726 | "version": "1.2.6", 727 | "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz", 728 | "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==", 729 | "dev": true 730 | }, 731 | "mkdirp": { 732 | "version": "0.5.6", 733 | "resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.6.tgz", 734 | "integrity": "sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==", 735 | "dev": true, 736 | "requires": { 737 | "minimist": "^1.2.6" 738 | } 739 | }, 740 | "ms": { 741 | "version": "2.1.2", 742 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", 743 | "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", 744 | "dev": true 745 | }, 746 | "once": { 747 | "version": "1.4.0", 748 | "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", 749 | "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", 750 | "dev": true, 751 | "requires": { 752 | "wrappy": "1" 753 | } 754 | }, 755 | "path-is-absolute": { 756 | "version": "1.0.1", 757 | "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", 758 | "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", 759 | "dev": true 760 | }, 761 | "process-nextick-args": { 762 | "version": "2.0.1", 763 | "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", 764 | "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", 765 | "dev": true 766 | }, 767 | "readable-stream": { 768 | "version": "2.3.7", 769 | "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.7.tgz", 770 | "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", 771 | "dev": true, 772 | "requires": { 773 | "core-util-is": "~1.0.0", 774 | "inherits": "~2.0.3", 775 | "isarray": "~1.0.0", 776 | "process-nextick-args": "~2.0.0", 777 | "safe-buffer": "~5.1.1", 778 | "string_decoder": "~1.1.1", 779 | "util-deprecate": "~1.0.1" 780 | } 781 | }, 782 | "rimraf": { 783 | "version": "3.0.2", 784 | "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", 785 | "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", 786 | "dev": true, 787 | "requires": { 788 | "glob": "^7.1.3" 789 | } 790 | }, 791 | "safe-buffer": { 792 | "version": "5.1.2", 793 | "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", 794 | "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", 795 | "dev": true 796 | }, 797 | "semver": { 798 | "version": "7.5.4", 799 | "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", 800 | "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", 801 | "requires": { 802 | "lru-cache": "^6.0.0" 803 | } 804 | }, 805 | "setimmediate": { 806 | "version": "1.0.5", 807 | "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", 808 | "integrity": "sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU=", 809 | "dev": true 810 | }, 811 | "string_decoder": { 812 | "version": "1.1.1", 813 | "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", 814 | "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", 815 | "dev": true, 816 | "requires": { 817 | "safe-buffer": "~5.1.0" 818 | } 819 | }, 820 | "traverse": { 821 | "version": "0.3.9", 822 | "resolved": "https://registry.npmjs.org/traverse/-/traverse-0.3.9.tgz", 823 | "integrity": "sha1-cXuPIgzAu3tE5AUUwisui7xw2Lk=", 824 | "dev": true 825 | }, 826 | "unzipper": { 827 | "version": "0.10.11", 828 | "resolved": "https://registry.npmjs.org/unzipper/-/unzipper-0.10.11.tgz", 829 | "integrity": "sha512-+BrAq2oFqWod5IESRjL3S8baohbevGcVA+teAIOYWM3pDVdseogqbzhhvvmiyQrUNKFUnDMtELW3X8ykbyDCJw==", 830 | "dev": true, 831 | "requires": { 832 | "big-integer": "^1.6.17", 833 | "binary": "~0.3.0", 834 | "bluebird": "~3.4.1", 835 | "buffer-indexof-polyfill": "~1.0.0", 836 | "duplexer2": "~0.1.4", 837 | "fstream": "^1.0.12", 838 | "graceful-fs": "^4.2.2", 839 | "listenercount": "~1.0.1", 840 | "readable-stream": "~2.3.6", 841 | "setimmediate": "~1.0.4" 842 | } 843 | }, 844 | "util-deprecate": { 845 | "version": "1.0.2", 846 | "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", 847 | "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=", 848 | "dev": true 849 | }, 850 | "vscode-jsonrpc": { 851 | "version": "6.0.0", 852 | "resolved": "https://registry.npmjs.org/vscode-jsonrpc/-/vscode-jsonrpc-6.0.0.tgz", 853 | "integrity": "sha512-wnJA4BnEjOSyFMvjZdpiOwhSq9uDoK8e/kpRJDTaMYzwlkrhG1fwDIZI94CLsLzlCK5cIbMMtFlJlfR57Lavmg==" 854 | }, 855 | "vscode-languageclient": { 856 | "version": "7.0.0", 857 | "resolved": "https://registry.npmjs.org/vscode-languageclient/-/vscode-languageclient-7.0.0.tgz", 858 | "integrity": "sha512-P9AXdAPlsCgslpP9pRxYPqkNYV7Xq8300/aZDpO35j1fJm/ncize8iGswzYlcvFw5DQUx4eVk+KvfXdL0rehNg==", 859 | "requires": { 860 | "minimatch": "^3.0.4", 861 | "semver": "^7.3.4", 862 | "vscode-languageserver-protocol": "3.16.0" 863 | } 864 | }, 865 | "vscode-languageserver-protocol": { 866 | "version": "3.16.0", 867 | "resolved": "https://registry.npmjs.org/vscode-languageserver-protocol/-/vscode-languageserver-protocol-3.16.0.tgz", 868 | "integrity": "sha512-sdeUoAawceQdgIfTI+sdcwkiK2KU+2cbEYA0agzM2uqaUy2UpnnGHtWTHVEtS0ES4zHU0eMFRGN+oQgDxlD66A==", 869 | "requires": { 870 | "vscode-jsonrpc": "6.0.0", 871 | "vscode-languageserver-types": "3.16.0" 872 | } 873 | }, 874 | "vscode-languageserver-types": { 875 | "version": "3.16.0", 876 | "resolved": "https://registry.npmjs.org/vscode-languageserver-types/-/vscode-languageserver-types-3.16.0.tgz", 877 | "integrity": "sha512-k8luDIWJWyenLc5ToFQQMaSrqCHiLwyKPHKPQZ5zz21vM+vIVUSvsRpcbiECH4WR88K2XZqc4ScRcZ7nk/jbeA==" 878 | }, 879 | "vscode-test": { 880 | "version": "1.6.1", 881 | "resolved": "https://registry.npmjs.org/vscode-test/-/vscode-test-1.6.1.tgz", 882 | "integrity": "sha512-086q88T2ca1k95mUzffvbzb7esqQNvJgiwY4h29ukPhFo8u+vXOOmelUoU5EQUHs3Of8+JuQ3oGdbVCqaxuTXA==", 883 | "dev": true, 884 | "requires": { 885 | "http-proxy-agent": "^4.0.1", 886 | "https-proxy-agent": "^5.0.0", 887 | "rimraf": "^3.0.2", 888 | "unzipper": "^0.10.11" 889 | } 890 | }, 891 | "wrappy": { 892 | "version": "1.0.2", 893 | "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", 894 | "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", 895 | "dev": true 896 | }, 897 | "yallist": { 898 | "version": "4.0.0", 899 | "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", 900 | "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" 901 | } 902 | } 903 | } 904 | -------------------------------------------------------------------------------- /client/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "erlang-ls-client", 3 | "version": "0.0.1", 4 | "publisher": "erlang-ls", 5 | "repository": { 6 | "type": "git", 7 | "url": "https://github.com/erlang-ls/vscode" 8 | }, 9 | "description": "VS Code client for erlang-ls", 10 | "engines": { 11 | "vscode": "^1.60.0" 12 | }, 13 | "scripts": { 14 | "compile": "tsc -b", 15 | "watch": "tsc -b -w" 16 | }, 17 | "author": "erlang-ls", 18 | "license": "Apache-2.0", 19 | "dependencies": { 20 | "vscode-languageclient": "^7.0.0" 21 | }, 22 | "devDependencies": { 23 | "@types/vscode": "^1.60.0", 24 | "vscode-test": "^1.5.1" 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /client/src/client.ts: -------------------------------------------------------------------------------- 1 | import * as path from 'path'; 2 | import { workspace, ExtensionContext, window } from 'vscode'; 3 | import { spawnSync } from 'child_process'; 4 | 5 | import { 6 | LanguageClient, 7 | LanguageClientOptions, 8 | ServerOptions, 9 | TransportKind 10 | } from 'vscode-languageclient/node'; 11 | 12 | let client: LanguageClient; 13 | 14 | export async function get_client(context: ExtensionContext): Promise { 15 | let clientOptions: LanguageClientOptions = { 16 | documentSelector: [{ scheme: 'file', language: 'erlang' }], 17 | synchronize: { 18 | fileEvents: [ 19 | workspace.createFileSystemWatcher('**/rebar.config'), 20 | workspace.createFileSystemWatcher('**/rebar.lock') 21 | ] 22 | }, 23 | middleware: { 24 | executeCommand: async (command, args, next) => { 25 | //Ask for user input if the argument contains {user_input: {type: string, text? : string}} 26 | //Used by Wrangler 27 | if (command.split(':').length >= 2 28 | && command.split(':')[1].startsWith("wrangler-") 29 | && args.length >= 1 30 | && "user_input" in args[0] 31 | && "type" in args[0].user_input) 32 | { 33 | var input: string; 34 | switch (args[0].user_input.type) { 35 | case "variable": 36 | input = await window.showInputBox({ 37 | placeHolder: args[0].user_input.text ?? "New name", validateInput: (value) => { 38 | if (!/^[A-Z][\_a-zA-Z0-9\@]*$/.test(value)) { 39 | return "Name must be a valid Erlang variable name"; 40 | } 41 | return null; 42 | } 43 | }); 44 | break; 45 | case "atom": 46 | input = await window.showInputBox({ 47 | placeHolder: args[0].user_input.text ?? "New name", validateInput: (value) => { 48 | if (!(/^[a-z][\_a-zA-Z0-9\@]*$/.test(value) || /^[\'][\_a-zA-Z0-9\@]*[\']$/.test(value))) { 49 | return "Name must be a valid Erlang atom"; 50 | } 51 | return null; 52 | } 53 | }); 54 | break; 55 | case "macro": 56 | input = await window.showInputBox({ 57 | placeHolder: args[0].user_input.text ?? "New name", validateInput: (value) => { 58 | if (!(/^[\_a-zA-Z0-9\@]+$/.test(value))) { 59 | return "Name must be a valid Erlang macro name"; 60 | } 61 | return null; 62 | } 63 | }); 64 | break; 65 | case "file": 66 | const uri = await window.showOpenDialog({ canSelectFiles: true, canSelectFolders: false, canSelectMany: false }); 67 | if (uri !== undefined) { 68 | input = uri[0].fsPath; 69 | } 70 | break; 71 | default: 72 | window.showErrorMessage("Unknown user input type: " + args[0].user_input.type); 73 | break; 74 | } 75 | args = args.slice(0); 76 | if (input !== undefined) { 77 | args[0].user_input.value = input; 78 | } else { 79 | //abort execution 80 | return; 81 | } 82 | }; 83 | return next(command, args); 84 | } 85 | } 86 | }; 87 | 88 | let serverPath = workspace.getConfiguration('erlang_ls').serverPath; 89 | if (serverPath === "") { 90 | serverPath = context.asAbsolutePath( 91 | path.join('erlang_ls', '_build', 'default', 'bin', 'erlang_ls') 92 | ); 93 | }; 94 | 95 | let logLevel = workspace.getConfiguration('erlang_ls').logLevel; 96 | 97 | let serverArgs = [ serverPath, "--log-level", logLevel ]; 98 | 99 | let logPath = workspace.getConfiguration('erlang_ls').logPath; 100 | if (logPath !== "") { 101 | serverArgs.push("--log-dir", logPath); 102 | } 103 | 104 | let escriptPath = workspace.getConfiguration('erlang_ls').escriptPath; 105 | if (escriptPath === "") { 106 | escriptPath = 'escript'; 107 | } 108 | 109 | let serverOptions: ServerOptions = { 110 | command: escriptPath, 111 | args: serverArgs, 112 | transport: TransportKind.stdio 113 | }; 114 | 115 | verifyExecutable(serverPath, escriptPath); 116 | 117 | return new LanguageClient( 118 | 'erlang_ls', 119 | 'Erlang LS', 120 | serverOptions, 121 | clientOptions 122 | ); 123 | } 124 | 125 | export function verifyExecutable(serverPath: string, escriptPath: string) { 126 | const res = spawnSync(escriptPath, [serverPath, "--version"]); 127 | if (res.status !== 0) { 128 | window.showErrorMessage('Could not start Language Server. Error: ' + res.stdout); 129 | } 130 | } 131 | -------------------------------------------------------------------------------- /client/src/debugger.ts: -------------------------------------------------------------------------------- 1 | import * as vscode from 'vscode'; 2 | import * as path from 'path'; 3 | 4 | const DEBUG_TYPE = 'erlang'; 5 | 6 | export function registerDebugAdapterDescriptorFactory( 7 | context: vscode.ExtensionContext 8 | ): vscode.Disposable { 9 | return vscode.debug.registerDebugAdapterDescriptorFactory( 10 | DEBUG_TYPE, 11 | new ErlangDebugAdapterExecutableFactory(context) 12 | ); 13 | } 14 | 15 | class ErlangDebugAdapterExecutableFactory implements vscode.DebugAdapterDescriptorFactory { 16 | context: vscode.ExtensionContext; 17 | 18 | constructor(context: vscode.ExtensionContext) { 19 | this.context = context; 20 | } 21 | 22 | async createDebugAdapterDescriptor( 23 | _session: vscode.DebugSession, 24 | _executable: vscode.DebugAdapterExecutable | undefined, 25 | ): Promise> { 26 | const erlangConfig = vscode.workspace; 27 | const executable = erlangConfig.getConfiguration('erlang_ls').get('dapPath') || ''; 28 | 29 | const command = erlangConfig.getConfiguration('erlang_ls').get('escriptPath') || 'escript'; 30 | let args; 31 | 32 | if (executable.length > 0) { 33 | args = [ executable.split(' ')[0] ]; 34 | } else { 35 | // use default 36 | args = [ this.context.asAbsolutePath( 37 | path.join('els_dap', '_build', 'default', 'bin', 'els_dap') 38 | ) ]; 39 | } 40 | return new vscode.DebugAdapterExecutable(command, args, undefined); 41 | } 42 | 43 | } 44 | -------------------------------------------------------------------------------- /client/src/extension.ts: -------------------------------------------------------------------------------- 1 | import * as path from 'path'; 2 | import { ExtensionContext } from 'vscode'; 3 | 4 | 5 | import { 6 | LanguageClient, 7 | } from 'vscode-languageclient/node'; 8 | 9 | import { get_client } from './client'; 10 | import { registerDebugAdapterDescriptorFactory } from './debugger'; 11 | 12 | let client: LanguageClient; 13 | 14 | export async function activate(context: ExtensionContext) { 15 | 16 | context.subscriptions.push(registerDebugAdapterDescriptorFactory(context)); 17 | 18 | client = await get_client(context), 19 | client.start(); 20 | } 21 | 22 | export function deactivate(): Thenable | undefined { 23 | if (!client) { 24 | return undefined; 25 | } 26 | return client.stop(); 27 | } 28 | -------------------------------------------------------------------------------- /client/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "module": "commonjs", 4 | "target": "es6", 5 | "outDir": "out", 6 | "rootDir": "src", 7 | "sourceMap": true 8 | }, 9 | "include": [ 10 | "src" 11 | ], 12 | "exclude": [ 13 | "node_modules", 14 | ".vscode-test" 15 | ] 16 | } 17 | -------------------------------------------------------------------------------- /language-configuration.json: -------------------------------------------------------------------------------- 1 | { 2 | "comments": { 3 | "lineComment": "%" 4 | }, 5 | "brackets": [ 6 | [ "(", ")" ], 7 | [ "[", "]" ], 8 | [ "{", "}" ] 9 | ], 10 | "autoClosingPairs": [ 11 | [ "(", ")" ], 12 | [ "[", "]" ], 13 | [ "{", "}" ], 14 | { "open": "'", "close": "'", "notIn": [ "string", "comment" ] }, 15 | { "open": "\"", "close": "\"", "notIn": [ "string" ] }, 16 | { "open": "<<\"", "close": "\">>", "notIn": [ "string" ] } 17 | ], 18 | "surroundingPairs": [ 19 | [ "(", ")" ], 20 | [ "[", "]" ], 21 | [ "{", "}" ], 22 | [ "'", "'" ], 23 | [ "\"", "\"" ] 24 | ], 25 | "indentationRules": { 26 | // Indent if a line ends brackets, "->" or most keywords. Also if prefixed 27 | // with "||". This should work with most formatting models. 28 | // The ((?!%).)* is to ensure this doesn't match inside comments. 29 | "increaseIndentPattern": "^((?!%).)*([{([]|->|after|begin|case|catch|fun|if|of|try|when|maybe|else|(\\|\\|.*))\\s*$", 30 | // Dedent after brackets, end or lone "->". The latter happens in a spec 31 | // with indented types, typically after "when". Only do this if it's _only_ 32 | // preceded by whitespace. 33 | "decreaseIndentPattern": "^\\s*([)}\\]]|end|else|->\\s*$)", 34 | // Indent if after an incomplete map association operator, list 35 | // comprehension and type specifier. But only once, then return to the 36 | // previous indent. 37 | "indentNextLinePattern": "^((?!%).)*(::|=>|:=|<-)\\s*$" 38 | }, 39 | "onEnterRules": [ 40 | { 41 | // Dedent after ";" or "." 42 | "beforeText": "^((?!%).)*[;.]", 43 | "action": { 44 | "indent": "outdent" 45 | } 46 | }, 47 | // Inside a comment, pressing enter should insert comment markers (%) as 48 | // appropriate. These three rules do just that. 49 | { 50 | "beforeText": "^\\s*%%%", 51 | "action": { 52 | "indent": "none", 53 | "appendText": "%%% " 54 | } 55 | }, 56 | { 57 | "beforeText": "^\\s*%%", 58 | "action": { 59 | "indent": "none", 60 | "appendText": "%% " 61 | } 62 | }, 63 | { 64 | "beforeText": "^\\s*%", 65 | "action": { 66 | "indent": "none", 67 | "appendText": "% " 68 | } 69 | } 70 | ] 71 | } 72 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "erlang-ls", 3 | "displayName": "Erlang LS", 4 | "version": "0.0.46", 5 | "publisher": "erlang-ls", 6 | "description": "The Visual Studio Code Extension for the Erlang Language Server", 7 | "categories": [ 8 | "Programming Languages", 9 | "Snippets", 10 | "Debuggers", 11 | "Formatters" 12 | ], 13 | "icon": "erlang_ls/images/erlang-ls-logo-small.png", 14 | "homepage": "https://erlang-ls.github.io", 15 | "repository": { 16 | "type": "git", 17 | "url": "https://github.com/erlang-ls/vscode.git" 18 | }, 19 | "bugs": { 20 | "url": "https://github.com/erlang-ls/vscode/issues" 21 | }, 22 | "main": "./client/out/extension.js", 23 | "scripts": { 24 | "package": "vsce package", 25 | "test": "echo \"Error: no test specified\" && exit 1", 26 | "vscode:prepublish": "cd client && npm run compile", 27 | "compile": "cd erlang_ls && rebar3 escriptize && cd ../els_dap && rebar3 escriptize && cd ../client && npm run compile", 28 | "watch": "cd client && npm run watch", 29 | "postinstall": "cd client && npm install" 30 | }, 31 | "author": "erlang_ls", 32 | "license": "Apache-2.0", 33 | "engines": { 34 | "vscode": "^1.60.0" 35 | }, 36 | "activationEvents": [ 37 | "onLanguage:erlang" 38 | ], 39 | "contributes": { 40 | "configuration": { 41 | "type": "object", 42 | "title": "Erlang LS", 43 | "properties": { 44 | "erlang_ls.trace.server": { 45 | "scope": "window", 46 | "type": "string", 47 | "enum": [ 48 | "off", 49 | "messages", 50 | "verbose" 51 | ], 52 | "default": "off", 53 | "description": "Traces the communication between VS Code and the Erlang language server." 54 | }, 55 | "erlang_ls.serverPath": { 56 | "scope": "window", 57 | "type": "string", 58 | "default": "", 59 | "description": "Override the default path of the erlang_ls executable with a custom one." 60 | }, 61 | "erlang_ls.dapPath": { 62 | "scope": "window", 63 | "type": "string", 64 | "default": "", 65 | "description": "Override the default path of the els_dap executable with a custom one." 66 | }, 67 | "erlang_ls.escriptPath": { 68 | "scope": "window", 69 | "type": "string", 70 | "default": "", 71 | "description": "Override the default path of the escript executable with a custom one." 72 | }, 73 | "erlang_ls.logPath": { 74 | "scope": "window", 75 | "type": "string", 76 | "default": "", 77 | "description": "Override the default directory erlang_ls logs to." 78 | }, 79 | "erlang_ls.logLevel": { 80 | "scope": "window", 81 | "enum": [ 82 | "none", 83 | "debug", 84 | "info", 85 | "notice", 86 | "warning", 87 | "error", 88 | "critical", 89 | "alert", 90 | "emergency" 91 | ], 92 | "default": "none", 93 | "description": "Log level of LS server" 94 | } 95 | } 96 | }, 97 | "languages": [ 98 | { 99 | "id": "erlang", 100 | "aliases": [ 101 | "Erlang" 102 | ], 103 | "extensions": [ 104 | ".erl", 105 | ".hrl", 106 | ".src", 107 | ".escript", 108 | ".config" 109 | ], 110 | "configuration": "./language-configuration.json" 111 | } 112 | ], 113 | "grammars": [ 114 | { 115 | "language": "erlang", 116 | "scopeName": "source.erlang", 117 | "path": "./grammar/Erlang.plist" 118 | } 119 | ], 120 | "breakpoints": [ 121 | { 122 | "language": "erlang" 123 | } 124 | ], 125 | "debuggers": [ 126 | { 127 | "type": "erlang", 128 | "label": "Erlang OTP Debugger", 129 | "initialConfigurations": [ 130 | { 131 | "name": "rebar shell", 132 | "type": "erlang", 133 | "request": "launch", 134 | "runinterminal": [ 135 | "rebar3", 136 | "shell", 137 | "--sname", 138 | "dap-project-node@localhost", 139 | "--setcookie", 140 | "COOKIE" 141 | ], 142 | "projectnode": "dap-project-node@localhost", 143 | "cookie": "COOKIE", 144 | "timeout": 300, 145 | "cwd": "${workspaceRoot}" 146 | }, 147 | { 148 | "name": "rebar shell --start-clean", 149 | "type": "erlang", 150 | "request": "launch", 151 | "runinterminal": [ 152 | "rebar3", 153 | "shell", 154 | "--sname", 155 | "dap-project-node@localhost", 156 | "--setcookie", 157 | "COOKIE", 158 | "--start-clean" 159 | ], 160 | "projectnode": "dap-project-node@localhost", 161 | "cookie": "COOKIE", 162 | "timeout": 300, 163 | "cwd": "${workspaceRoot}" 164 | } 165 | ], 166 | "configurationAttributes": { 167 | "launch": { 168 | "required": [ 169 | "projectnode" 170 | ], 171 | "properties": { 172 | "cwd": { 173 | "type": "string", 174 | "description": "Working directory for runinterminal", 175 | "default": "${workspaceRoot}" 176 | }, 177 | "stopOnEntry": { 178 | "type": "boolean", 179 | "description": "Stop after launch (unused)", 180 | "default": "true" 181 | }, 182 | "module": { 183 | "type": "string", 184 | "description": "Module for the launch M:F(A)", 185 | "default": "io" 186 | }, 187 | "function": { 188 | "type": "string", 189 | "description": "Funtion for the launch M:F(A)", 190 | "default": "format" 191 | }, 192 | "args": { 193 | "type": "string", 194 | "description": "Args for the launch M:F(A)", 195 | "default": "[\"Hello World\"]" 196 | }, 197 | "runinterminal": { 198 | "type": "array", 199 | "description": "launch command", 200 | "default": [ 201 | "rebar3", 202 | "shell", 203 | "--sname", 204 | "dap-project-node@localhost", 205 | "--setcookie", 206 | "COOKIE" 207 | ] 208 | }, 209 | "projectnode": { 210 | "type": "string", 211 | "description": "name of the target node that the debugger connects to", 212 | "default": "dap-project-node@localhost" 213 | }, 214 | "use_long_names": { 215 | "type": "boolean", 216 | "description": "start erlang distribution with long names (-name option)", 217 | "default": false 218 | }, 219 | "cookie": { 220 | "type": "string", 221 | "description": "The magic cookie used to connect to the projectnode", 222 | "default": "COOKIE" 223 | }, 224 | "timeout": { 225 | "type": "integer", 226 | "description": "Timeout for connecting to the projectnode after starting the debugger.", 227 | "default": 300 228 | } 229 | } 230 | } 231 | } 232 | } 233 | ] 234 | }, 235 | "files": [ 236 | "erlang_ls/_build/default/bin/erlang_ls", 237 | "els_dap/_build/default/bin/els_dap", 238 | "erlang.tmbundle" 239 | ], 240 | "devDependencies": { 241 | "@types/mocha": "^9.0.0", 242 | "@types/node": "^20.0.0", 243 | "@typescript-eslint/parser": "^4.19.0", 244 | "eslint": "^7.23.0", 245 | "mocha": "^9.1.2", 246 | "typescript": "^4.2.3", 247 | "@vscode/vsce": "^3.1.0" 248 | } 249 | } 250 | --------------------------------------------------------------------------------