├── .eslintrc.json ├── .gitattributes ├── .gitignore ├── .vscode ├── extensions.json ├── language-configurations.json ├── launch.json ├── settings.json └── tasks.json ├── .vscodeignore ├── CHANGELOG.md ├── LICENSE ├── README.md ├── bin ├── h2o-x86_64-apple-darwin ├── h2o-x86_64-unknown-linux ├── profile.sb └── wrap-h2o ├── images ├── animal_chara_computer_penguin.png ├── demo-autocomplete.gif ├── demo-mouseover.gif ├── vscode-h2o-completion.gif ├── vscode-h2o-hover.gif └── vscode-shell-command-explorer.png ├── package-lock.json ├── package.json ├── src ├── analyzer.ts ├── cacheFetcher.ts ├── command.ts ├── commandExplorer.ts ├── extension.ts ├── test │ ├── runTest.ts │ └── suite │ │ ├── extension.test.ts │ │ └── index.ts └── utils.ts ├── tree-sitter-bash.wasm └── tsconfig.json /.eslintrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "root": true, 3 | "parser": "@typescript-eslint/parser", 4 | "parserOptions": { 5 | "ecmaVersion": 6, 6 | "sourceType": "module" 7 | }, 8 | "plugins": [ 9 | "@typescript-eslint" 10 | ], 11 | "rules": { 12 | "@typescript-eslint/naming-convention": "warn", 13 | "@typescript-eslint/semi": "warn", 14 | "curly": "warn", 15 | "eqeqeq": "warn", 16 | "no-throw-literal": "warn", 17 | "semi": "off" 18 | }, 19 | "ignorePatterns": [ 20 | "out", 21 | "dist", 22 | "**/*.d.ts" 23 | ] 24 | } 25 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | bin/h2o-x86_64-apple-darwin filter=lfs diff=lfs merge=lfs -text 2 | bin/h2o-x86_64-unknown-linux filter=lfs diff=lfs merge=lfs -text 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | out 2 | dist 3 | node_modules 4 | .vscode-test/ 5 | *.vsix 6 | -------------------------------------------------------------------------------- /.vscode/extensions.json: -------------------------------------------------------------------------------- 1 | { 2 | // See http://go.microsoft.com/fwlink/?LinkId=827846 3 | // for the documentation about the extensions.json format 4 | "recommendations": [ 5 | "dbaeumer.vscode-eslint" 6 | ] 7 | } 8 | -------------------------------------------------------------------------------- /.vscode/language-configurations.json: -------------------------------------------------------------------------------- 1 | { 2 | "wordPattern": "(-?\\d*\\.\\d\\w*)|([^\\`\\~\\!\\@\\#\\%\\^\\&\\*\\(\\)\\=\\+\\[\\{\\]\\}\\\\\\|\\;\\:\\'\\\"\\,\\.\\<\\>\\/\\?\\s]+)" 3 | } -------------------------------------------------------------------------------- /.vscode/launch.json: -------------------------------------------------------------------------------- 1 | // A launch configuration that compiles the extension and then opens it inside a new window 2 | // Use IntelliSense to learn about possible attributes. 3 | // Hover to view descriptions of existing attributes. 4 | // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 5 | { 6 | "version": "0.2.0", 7 | "configurations": [ 8 | { 9 | "name": "Run Extension", 10 | "type": "extensionHost", 11 | "request": "launch", 12 | "args": [ 13 | "--extensionDevelopmentPath=${workspaceFolder}" 14 | ], 15 | "outFiles": [ 16 | "${workspaceFolder}/out/**/*.js" 17 | ], 18 | "preLaunchTask": "${defaultBuildTask}" 19 | }, 20 | { 21 | "name": "Extension Tests", 22 | "type": "extensionHost", 23 | "request": "launch", 24 | "args": [ 25 | "--extensionDevelopmentPath=${workspaceFolder}", 26 | "--extensionTestsPath=${workspaceFolder}/out/test/suite/index" 27 | ], 28 | "outFiles": [ 29 | "${workspaceFolder}/out/test/**/*.js" 30 | ], 31 | "preLaunchTask": "${defaultBuildTask}" 32 | } 33 | ] 34 | } 35 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | // Place your settings in this file to overwrite default and user settings. 2 | { 3 | "files.exclude": { 4 | "out": false // set this to true to hide the "out" folder with the compiled JS files 5 | }, 6 | "search.exclude": { 7 | "out": true // set this to false to include "out" folder in search results 8 | }, 9 | // Turn off tsc task auto detection since we have the necessary tasks as npm scripts 10 | "typescript.tsc.autoDetect": "off", 11 | 12 | "[shellscript]": { 13 | "editor.wordSeparators": "`~!@#$%^&*()=+[{]}\\|;:'\",.<>/?" 14 | } 15 | } -------------------------------------------------------------------------------- /.vscode/tasks.json: -------------------------------------------------------------------------------- 1 | // See https://go.microsoft.com/fwlink/?LinkId=733558 2 | // for the documentation about the tasks.json format 3 | { 4 | "version": "2.0.0", 5 | "tasks": [ 6 | { 7 | "type": "npm", 8 | "script": "watch", 9 | "problemMatcher": "$tsc-watch", 10 | "isBackground": true, 11 | "presentation": { 12 | "reveal": "never" 13 | }, 14 | "group": { 15 | "kind": "build", 16 | "isDefault": true 17 | } 18 | } 19 | ] 20 | } 21 | -------------------------------------------------------------------------------- /.vscodeignore: -------------------------------------------------------------------------------- 1 | .vscode/** 2 | .vscode-test/** 3 | out/test/** 4 | 5 | src/** 6 | .gitignore 7 | .yarnrc 8 | vsc-extension-quickstart.md 9 | **/tsconfig.json 10 | **/.eslintrc.json 11 | **/*.map 12 | **/*.ts 13 | -------------------------------------------------------------------------------- /CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # Change Log 2 | ## [0.2.14] (2023-10-14) 3 | - Update README with instruction that Command Palettes work only in "Shell Script" mode. 4 | 5 | ## [0.2.13] (2023-10-11) 6 | - Fix [Issue #8](https://github.com/yamaton/vscode-h2o/issues/8) thanks to [@vdesabou](https://github.com/vdesabou) 7 | 8 | ## [0.2.12] (2023-09-09) 9 | - Fix the extension not activated on WSL2 with dependency updates 10 | 11 | ## [0.2.11] (2023-08-10) 12 | - Fix Runtime errors in edits and saves 13 | 14 | ## [0.2.10] (2023-08-09) 15 | - Do not flood logs when command specs are handled in batch 16 | - Update dependencies for security 17 | - Rephrase README 18 | - (Fix dates in this change log) 19 | 20 | ## [0.2.9] (2023-02-07) 21 | - Fix problems by removing unnecessary entries in package.json 22 | 23 | ## [0.2.8] (2023-02-07) 24 | - Improve command usage and TLDR formatting 25 | - Handle commands starting with `nohup` 26 | 27 | ## [0.2.7] (2023-02-02) 28 | - Fix hover over unregistered old-style options 29 | 30 | ## [0.2.6] (2023-01-28) 31 | - Show usage in hovers 32 | - Show description in hovers when appropriate 33 | - Update `h2o` (command spec parser) to v0.4.6 34 | 35 | ## [0.2.5] (2022-12-29) 36 | - Fix completion range discussed in https://github.com/yamaton/h2o-curated-data/issues/2 37 | 38 | ## [0.2.4] (2022-10-24) 39 | - Fix completion shown after semicolons. 40 | 41 | ## [0.2.3] (2022-03-18) 42 | - Update README 43 | 44 | ## [0.2.2] (2022-03-18) 45 | - Fix an error when loading a command without an argument. 46 | 47 | ## [0.2.1] (2022-03-17) 48 | - Show "tldr" pages at the command hover if available in the command spec 49 | - Support `tldr`, `inheritedOptions`, and `aliases` fields in the command spec. 50 | 51 | ## [0.2.0] (2022-03-02) 52 | - Add "Shell Commands" Explorer view 53 | - Fix to work with built-in commands like echo and hash 54 | - Fix case in the title to "Shell script command completion" 55 | - Update publisher name / email address 56 | 57 | ## [0.1.3] (2022-02-23) 58 | - Fix ridiculously long loading of CLI packages 59 | - Remove redundant operations 60 | 61 | ## [0.1.2] (2022-02-23) 62 | - Add loading individual command spec from 'experimental' 63 | - Fix broken links in downloading CLI packages (general and bio) 64 | - Bump H2O to v0.3.2 65 | 66 | ## [0.1.1] (2022-01-28) 67 | - Remove unused dev dependencies 68 | 69 | ## [0.1.0] (2021-12-18) 70 | - Support multi-level subcommands 71 | - Rename package to "Shell Script command completion" 72 | - Bump H2O to v0.2.0 73 | 74 | ## [0.0.20] (2021-07-22) 75 | - Rename command "Load General-Purpose CLI Data" to "Load Common CLI Data" 76 | - Suppress command-name completion after typing space 77 | - Bump H2O to v0.1.18 78 | - Use sandboxing on macOS with `sandbox-exec` 79 | - Filter duplicate options with hand-engineered score 80 | 81 | ## [0.0.19] (2021-07-18) 82 | - Fix icon 83 | 84 | ## [0.0.18] (2021-07-18) 85 | - Bump H2O to v0.1.17 86 | - Fix a bug in checking manpage availability 87 | - Add more help query scanning 88 | - Minior fixes 89 | - **[WARNING]** temporary disable sandboxing for performance 90 | - Add icon (Credit: https://www.irasutoya.com/) 91 | 92 | ## [0.0.17] (2021-07-14) 93 | - Show description in all lines of subcommand and option/flag completions 94 | - Bump H2O to v0.1.15 95 | - Bugfixes 96 | 97 | ## [0.0.16] 98 | - Bump H2O to v0.1.14 99 | - Much better macos support 100 | - Improved parsing 101 | 102 | ## [0.0.15] 103 | - Support the multi-lined command where continued line ends with `\` 104 | - Fix hover not working on `--option=arg` 105 | - Fix hover not working on a short option immediately followed by an argument `-oArgument` 106 | - Fix completion candidates not ignoring properly after `--option=arg` 107 | 108 | ## [0.0.14] 109 | - Bump H2O to v0.1.12 110 | - Bugfixes and performance improvements 111 | - Introduce non-alphabetical ordering of completion items 112 | - Subcommands appear before options 113 | - Ordering respects the source 114 | 115 | ## [0.0.13] 116 | - Remove command "Download and Force Update Local CLI Data" 117 | - Add command "Load General-Purpose CLI Data" 118 | - Add command "Load Bioinformatics CLI Data" 119 | - Add command "Remove Bioinformatics CLI Data" 120 | 121 | ## [0.0.12] 122 | - Suppress command completion when other completions are available 123 | 124 | ## [0.0.11] 125 | - Reintroduce command completion 126 | - Add command "Download and Force Update Local CLI Data" 127 | - Bugfixes including crash when disconnected 128 | 129 | ## [0.0.10] 130 | - Revert to 0.0.8+ 131 | 132 | ## [0.0.9] 133 | - Add command completion 134 | - Code refactoring 135 | 136 | ## [0.0.8] 137 | - Change the display name to "Shell Completion" 138 | - Fix the bug not showing completions in some cases. 139 | 140 | ## [0.0.7] 141 | - Fix a critical bug not showing completions properly 142 | - Bump H2o to v0.1.10 143 | - Bugfixes 144 | 145 | ## [0.0.6] 146 | - Fetch curated data from GitHub at startup 147 | - Bump H2o to v0.1.9 148 | - Use Bubblewrap (sandbox) in Linux if available 149 | - Fail fast than producing junk 150 | - Change message formatting in Hover 151 | 152 | ## [0.0.5] 153 | - Fix link in README 154 | 155 | ## [0.0.4] 156 | - Add completion and hover GIF to README 157 | 158 | ## [0.0.3] 159 | - Bundle macos executable, in addition to linux 160 | - Bump H2O to v0.1.7 161 | - Make path to H2O configurable (default: "") 162 | 163 | - Initial release -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2022 Yamato Matsuoka 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Shell Script Command Completion 2 | 3 | This extension brings autocompletion and introspection of shell commands to VS Code, enhancing the **Shell Script mode**. 4 | 5 | ## Features 6 | 7 | * Autocomplete command-line options, flags, and subcommands 8 | * Hover to get descriptions for subcommands and options/flags 9 | * **Zero configuration** required 10 | * 🧬 Opt-in support for bioinformatics CLI tools 🧬 11 | 12 | ## Demos 13 | 14 | ### Autocomplete in Shell Script 15 | 16 | ![shellcomp](https://raw.githubusercontent.com/yamaton/vscode-h2o/main/images/demo-autocomplete.gif) 17 | 18 | ### Introspection with Hover 19 | 20 | ![hover](https://raw.githubusercontent.com/yamaton/vscode-h2o/main/images/demo-mouseover.gif) 21 | 22 | ## Supported Commands 23 | 24 | The extension comes preloaded with 400+ CLI specifications but can also dynamically create specs by scanning man pages or `--help` documents. The preloaded specs include common tools like `git`, `npm`, `docker`, `terraform`, and many more. See the complete list in [general.txt](https://github.com/yamaton/h2o-curated-data/blob/main/general.txt). If you'd like more tools to be added, please [submit a request here](https://github.com/yamaton/h2o-curated-data/issues/1). 25 | 26 | ### 🧬 Extra Command Specs for Bioinformatics 27 | 28 | Over 500 command specifications for bioinformatics tools can be optionally loaded. In "Shell Script" mode, press `Ctrl`+`Shift`+`P` (or `⌘`+`⇧`+`P` on macOS) and select `Shell Completion: Load Bioinformatics CLI Specs`. If the commands are not recognized, you may need to clear the cache as described below. The supported tools include `BLAST`, `GATK`, `seqkit`, `samtools`, and more. View [bio.txt](https://github.com/yamaton/h2o-curated-data/blob/main/bio.txt) for the full list and [submit any requests for additional tools here](https://github.com/yamaton/h2o-curated-data/issues/1). 29 | 30 | ## Managing Command Specs 31 | 32 | The "Shell Commands" Explorer in the Side Bar displays loaded command specifications. 33 | 34 | ![](https://raw.githubusercontent.com/yamaton/vscode-h2o/main/images/vscode-shell-command-explorer.png) 35 | 36 | ## 🔥 Troubleshooting 37 | 38 | ### 😞 Not Working? 39 | 40 | * If the command is on [this list](https://github.com/yamaton/h2o-curated-data/blob/main/general.txt), activate "Shell Script" mode, then type `Ctrl`+`Shift`+`P` (or `⌘`+`⇧`+`P` on macOS) and choose `Shell Completion: Load Common CLI Specs` to reload the common CLI specs. 41 | * If the command is in [this bio list](https://github.com/yamaton/h2o-curated-data/blob/main/bio.txt), activate "Shell Script" mode, then type `Ctrl`+`Shift`+`P` (or `⌘`+`⇧`+`P` on macOS) and choose `Shell Completion: Load Bioinformatics CLI Specs` to reload the bioinformatics CLI specs. 42 | * If the command is still not recognized, activate "Shell Script" mode, then type `Ctrl`+`Shift`+`P` (or `⌘`+`⇧`+`P` on macOS) and choose `Shell Completion: Remove Command Spec`, then enter the name of the command to remove it from the cache. Our program will then try to recreate the CLI spec. 43 | 44 | ### 😞 Annoyed by Aggressive Suggestions? 45 | 46 | Adjust suggestions with the VS Code settings: 47 | * Suppress **Quick Suggestions** 48 | * Deactivate SPACE-key triggering with **Suggest on Trigger Characters** 49 | 50 | Note: These settings apply to other language modes as well. 51 | 52 | ### 😞 Annoyed by Unwanted Commands? 53 | 54 | Use the Shell Commands Explorer to remove unnecessary command specs. To remove all bioinformatics commands, activate "Shell Script" mode, type `Ctrl`+`Shift`+`P` (or `⌘`+`⇧`+`P` on macOS), and choose `Shell Completion: Remove Bioinformatics CLI Specs`. 55 | 56 | ## 🔧 How the Extension Works 57 | 58 | * Utilizes [preprocessed specs](https://github.com/yamaton/h2o-curated-data/tree/main/general/json) when available. 59 | * Extracts CLI information by parsing `man ` or ` --help`. 60 | * Runs on Linux/WSL and macOS only. 61 | * Depends on [tree-sitter](https://tree-sitter.github.io/tree-sitter/) to understand the shell script structure. 62 | 63 | ## 🛡️ Security with Sandboxing 64 | 65 | The extension executes unrecognized commands with `--help` to gather information, potentially posing a risk if untrusted programs are present locally. To mitigate this risk, it uses a sandbox environment if available, ensuring that unrecognized commands run in a controlled and secure environment, limiting network and filesystem access. 66 | 67 | * macOS: Always runs in a sandbox with `sandbox-exec`. 68 | * **Linux or WSL**: Consider installing **[bubblewrap](https://wiki.archlinux.org/title/Bubblewrap)**. 69 | 70 | ## ⚠️ Known Issues 71 | 72 | * Autocomplete and hover introspection require either: 73 | * The command in [preprocessed CLI specs](https://github.com/yamaton/h2o-curated-data/tree/main/general/json) to be loaded at startup. 74 | * Successful extraction of CLI information by the included parser from the local environment. 75 | -------------------------------------------------------------------------------- /bin/h2o-x86_64-apple-darwin: -------------------------------------------------------------------------------- 1 | version https://git-lfs.github.com/spec/v1 2 | oid sha256:d2676f5b846b7afbeda93dc15bd90585b1741f86b7db440d4c4810907e9eef1a 3 | size 3586320 4 | -------------------------------------------------------------------------------- /bin/h2o-x86_64-unknown-linux: -------------------------------------------------------------------------------- 1 | version https://git-lfs.github.com/spec/v1 2 | oid sha256:4e43d70b84859c3cb07c61acb19881955b5fc802c9976966f31368ebf2d17dc6 3 | size 27630256 4 | -------------------------------------------------------------------------------- /bin/profile.sb: -------------------------------------------------------------------------------- 1 | (version 1) 2 | (allow default) 3 | (deny file-write*) 4 | (deny file-write-data) 5 | (deny network*) 6 | -------------------------------------------------------------------------------- /bin/wrap-h2o: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Execute H2O executable within bubblewrap if available. 4 | # 5 | # Usage: wrap-h2o 6 | # 7 | # Example: 8 | # $ wrap-h2o ./h2o-x86_64-unknown-linux ls 9 | # 10 | 11 | readonly h2opath="$1" 12 | readonly cmd="$2" 13 | # https://stackoverflow.com/a/246128/524526 14 | BASEDIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )" 15 | readonly BASEDIR 16 | 17 | if [[ "$(command -v "$h2opath")" ]] && [[ "$(command -v "$cmd")" ]]; then 18 | if [[ "$(uname -s)" == "Linux" ]] && [[ "$(command -v bwrap)" ]]; then 19 | echo "[info] bwrap!" 1>&2 20 | bwrap --ro-bind / / --dev /dev --tmpfs /tmp --unshare-all -- "$h2opath" --command "$cmd" --format json 21 | elif [[ "$(uname -s)" == "Darwin" ]] && [[ "$(command -v sandbox-exec)" ]]; then 22 | echo "[info] sandbox-exec!" 1>&2 23 | sandbox-exec -f "$BASEDIR"/profile.sb -- "$h2opath" --command "$cmd" --format json 24 | else 25 | echo "[warn] no sandbox running!" 1>&2 26 | "$h2opath" --command "$cmd" --format json 27 | fi 28 | else 29 | exit 127 30 | fi 31 | -------------------------------------------------------------------------------- /images/animal_chara_computer_penguin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yamaton/vscode-h2o/b35e037b127748cfda01253c5a15c2fe5f359ae5/images/animal_chara_computer_penguin.png -------------------------------------------------------------------------------- /images/demo-autocomplete.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yamaton/vscode-h2o/b35e037b127748cfda01253c5a15c2fe5f359ae5/images/demo-autocomplete.gif -------------------------------------------------------------------------------- /images/demo-mouseover.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yamaton/vscode-h2o/b35e037b127748cfda01253c5a15c2fe5f359ae5/images/demo-mouseover.gif -------------------------------------------------------------------------------- /images/vscode-h2o-completion.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yamaton/vscode-h2o/b35e037b127748cfda01253c5a15c2fe5f359ae5/images/vscode-h2o-completion.gif -------------------------------------------------------------------------------- /images/vscode-h2o-hover.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yamaton/vscode-h2o/b35e037b127748cfda01253c5a15c2fe5f359ae5/images/vscode-h2o-hover.gif -------------------------------------------------------------------------------- /images/vscode-shell-command-explorer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yamaton/vscode-h2o/b35e037b127748cfda01253c5a15c2fe5f359ae5/images/vscode-shell-command-explorer.png -------------------------------------------------------------------------------- /package-lock.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "vscode-h2o", 3 | "version": "0.2.13", 4 | "lockfileVersion": 3, 5 | "requires": true, 6 | "packages": { 7 | "": { 8 | "name": "vscode-h2o", 9 | "version": "0.2.13", 10 | "license": "MIT", 11 | "dependencies": { 12 | "node-fetch": "^2.6.6", 13 | "pako": "^2.0.4", 14 | "web-tree-sitter": "^0.20.8" 15 | }, 16 | "devDependencies": { 17 | "@types/glob": "^7.2.0", 18 | "@types/mocha": "^10.0.0", 19 | "@types/node": "^18.11.9", 20 | "@types/node-fetch": "^2.5.12", 21 | "@types/pako": "^1.0.2", 22 | "@types/vscode": "^1.63.0", 23 | "@typescript-eslint/eslint-plugin": "^5.7.0", 24 | "@typescript-eslint/parser": "^5.7.0", 25 | "@vscode/test-electron": "^2.1.5", 26 | "eslint": "^8.4.1", 27 | "glob": "^7.2.0", 28 | "mocha": "^10.0.0", 29 | "typescript": "^4.5.4" 30 | }, 31 | "engines": { 32 | "vscode": "^1.63.0" 33 | } 34 | }, 35 | "node_modules/@aashutoshrathi/word-wrap": { 36 | "version": "1.2.6", 37 | "resolved": "https://registry.npmjs.org/@aashutoshrathi/word-wrap/-/word-wrap-1.2.6.tgz", 38 | "integrity": "sha512-1Yjs2SvM8TflER/OD3cOjhWWOZb58A2t7wpE2S9XfBYTiIl+XFhQG2bjy4Pu1I+EAlCNUzRDYDdFwFYUKvXcIA==", 39 | "dev": true, 40 | "engines": { 41 | "node": ">=0.10.0" 42 | } 43 | }, 44 | "node_modules/@eslint-community/eslint-utils": { 45 | "version": "4.4.0", 46 | "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", 47 | "integrity": "sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==", 48 | "dev": true, 49 | "dependencies": { 50 | "eslint-visitor-keys": "^3.3.0" 51 | }, 52 | "engines": { 53 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 54 | }, 55 | "peerDependencies": { 56 | "eslint": "^6.0.0 || ^7.0.0 || >=8.0.0" 57 | } 58 | }, 59 | "node_modules/@eslint-community/regexpp": { 60 | "version": "4.8.0", 61 | "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.8.0.tgz", 62 | "integrity": "sha512-JylOEEzDiOryeUnFbQz+oViCXS0KsvR1mvHkoMiu5+UiBvy+RYX7tzlIIIEstF/gVa2tj9AQXk3dgnxv6KxhFg==", 63 | "dev": true, 64 | "engines": { 65 | "node": "^12.0.0 || ^14.0.0 || >=16.0.0" 66 | } 67 | }, 68 | "node_modules/@eslint/eslintrc": { 69 | "version": "2.1.2", 70 | "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.1.2.tgz", 71 | "integrity": "sha512-+wvgpDsrB1YqAMdEUCcnTlpfVBH7Vqn6A/NT3D8WVXFIaKMlErPIZT3oCIAVCOtarRpMtelZLqJeU3t7WY6X6g==", 72 | "dev": true, 73 | "dependencies": { 74 | "ajv": "^6.12.4", 75 | "debug": "^4.3.2", 76 | "espree": "^9.6.0", 77 | "globals": "^13.19.0", 78 | "ignore": "^5.2.0", 79 | "import-fresh": "^3.2.1", 80 | "js-yaml": "^4.1.0", 81 | "minimatch": "^3.1.2", 82 | "strip-json-comments": "^3.1.1" 83 | }, 84 | "engines": { 85 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 86 | }, 87 | "funding": { 88 | "url": "https://opencollective.com/eslint" 89 | } 90 | }, 91 | "node_modules/@eslint/js": { 92 | "version": "8.49.0", 93 | "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.49.0.tgz", 94 | "integrity": "sha512-1S8uAY/MTJqVx0SC4epBq+N2yhuwtNwLbJYNZyhL2pO1ZVKn5HFXav5T41Ryzy9K9V7ZId2JB2oy/W4aCd9/2w==", 95 | "dev": true, 96 | "engines": { 97 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 98 | } 99 | }, 100 | "node_modules/@humanwhocodes/config-array": { 101 | "version": "0.11.11", 102 | "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.11.tgz", 103 | "integrity": "sha512-N2brEuAadi0CcdeMXUkhbZB84eskAc8MEX1By6qEchoVywSgXPIjou4rYsl0V3Hj0ZnuGycGCjdNgockbzeWNA==", 104 | "dev": true, 105 | "dependencies": { 106 | "@humanwhocodes/object-schema": "^1.2.1", 107 | "debug": "^4.1.1", 108 | "minimatch": "^3.0.5" 109 | }, 110 | "engines": { 111 | "node": ">=10.10.0" 112 | } 113 | }, 114 | "node_modules/@humanwhocodes/module-importer": { 115 | "version": "1.0.1", 116 | "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", 117 | "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==", 118 | "dev": true, 119 | "engines": { 120 | "node": ">=12.22" 121 | }, 122 | "funding": { 123 | "type": "github", 124 | "url": "https://github.com/sponsors/nzakas" 125 | } 126 | }, 127 | "node_modules/@humanwhocodes/object-schema": { 128 | "version": "1.2.1", 129 | "resolved": "https://registry.npmjs.org/@humanwhocodes/object-schema/-/object-schema-1.2.1.tgz", 130 | "integrity": "sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==", 131 | "dev": true 132 | }, 133 | "node_modules/@nodelib/fs.scandir": { 134 | "version": "2.1.5", 135 | "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", 136 | "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", 137 | "dev": true, 138 | "dependencies": { 139 | "@nodelib/fs.stat": "2.0.5", 140 | "run-parallel": "^1.1.9" 141 | }, 142 | "engines": { 143 | "node": ">= 8" 144 | } 145 | }, 146 | "node_modules/@nodelib/fs.stat": { 147 | "version": "2.0.5", 148 | "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", 149 | "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", 150 | "dev": true, 151 | "engines": { 152 | "node": ">= 8" 153 | } 154 | }, 155 | "node_modules/@nodelib/fs.walk": { 156 | "version": "1.2.8", 157 | "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", 158 | "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", 159 | "dev": true, 160 | "dependencies": { 161 | "@nodelib/fs.scandir": "2.1.5", 162 | "fastq": "^1.6.0" 163 | }, 164 | "engines": { 165 | "node": ">= 8" 166 | } 167 | }, 168 | "node_modules/@tootallnate/once": { 169 | "version": "1.1.2", 170 | "resolved": "https://registry.npmjs.org/@tootallnate/once/-/once-1.1.2.tgz", 171 | "integrity": "sha512-RbzJvlNzmRq5c3O09UipeuXno4tA1FE6ikOjxZK0tuxVv3412l64l5t1W5pj4+rJq9vpkm/kwiR07aZXnsKPxw==", 172 | "dev": true, 173 | "engines": { 174 | "node": ">= 6" 175 | } 176 | }, 177 | "node_modules/@types/glob": { 178 | "version": "7.2.0", 179 | "resolved": "https://registry.npmjs.org/@types/glob/-/glob-7.2.0.tgz", 180 | "integrity": "sha512-ZUxbzKl0IfJILTS6t7ip5fQQM/J3TJYubDm3nMbgubNNYS62eXeUpoLUC8/7fJNiFYHTrGPQn7hspDUzIHX3UA==", 181 | "dev": true, 182 | "dependencies": { 183 | "@types/minimatch": "*", 184 | "@types/node": "*" 185 | } 186 | }, 187 | "node_modules/@types/json-schema": { 188 | "version": "7.0.12", 189 | "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.12.tgz", 190 | "integrity": "sha512-Hr5Jfhc9eYOQNPYO5WLDq/n4jqijdHNlDXjuAQkkt+mWdQR+XJToOHrsD4cPaMXpn6KO7y2+wM8AZEs8VpBLVA==", 191 | "dev": true 192 | }, 193 | "node_modules/@types/minimatch": { 194 | "version": "5.1.2", 195 | "resolved": "https://registry.npmjs.org/@types/minimatch/-/minimatch-5.1.2.tgz", 196 | "integrity": "sha512-K0VQKziLUWkVKiRVrx4a40iPaxTUefQmjtkQofBkYRcoaaL/8rhwDWww9qWbrgicNOgnpIsMxyNIUM4+n6dUIA==", 197 | "dev": true 198 | }, 199 | "node_modules/@types/mocha": { 200 | "version": "10.0.1", 201 | "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-10.0.1.tgz", 202 | "integrity": "sha512-/fvYntiO1GeICvqbQ3doGDIP97vWmvFt83GKguJ6prmQM2iXZfFcq6YE8KteFyRtX2/h5Hf91BYvPodJKFYv5Q==", 203 | "dev": true 204 | }, 205 | "node_modules/@types/node": { 206 | "version": "18.17.15", 207 | "resolved": "https://registry.npmjs.org/@types/node/-/node-18.17.15.tgz", 208 | "integrity": "sha512-2yrWpBk32tvV/JAd3HNHWuZn/VDN1P+72hWirHnvsvTGSqbANi+kSeuQR9yAHnbvaBvHDsoTdXV0Fe+iRtHLKA==", 209 | "dev": true 210 | }, 211 | "node_modules/@types/node-fetch": { 212 | "version": "2.6.4", 213 | "resolved": "https://registry.npmjs.org/@types/node-fetch/-/node-fetch-2.6.4.tgz", 214 | "integrity": "sha512-1ZX9fcN4Rvkvgv4E6PAY5WXUFWFcRWxZa3EW83UjycOB9ljJCedb2CupIP4RZMEwF/M3eTcCihbBRgwtGbg5Rg==", 215 | "dev": true, 216 | "dependencies": { 217 | "@types/node": "*", 218 | "form-data": "^3.0.0" 219 | } 220 | }, 221 | "node_modules/@types/pako": { 222 | "version": "1.0.4", 223 | "resolved": "https://registry.npmjs.org/@types/pako/-/pako-1.0.4.tgz", 224 | "integrity": "sha512-Z+5bJSm28EXBSUJEgx29ioWeEEHUh6TiMkZHDhLwjc9wVFH+ressbkmX6waUZc5R3Gobn4Qu5llGxaoflZ+yhA==", 225 | "dev": true 226 | }, 227 | "node_modules/@types/semver": { 228 | "version": "7.5.1", 229 | "resolved": "https://registry.npmjs.org/@types/semver/-/semver-7.5.1.tgz", 230 | "integrity": "sha512-cJRQXpObxfNKkFAZbJl2yjWtJCqELQIdShsogr1d2MilP8dKD9TE/nEKHkJgUNHdGKCQaf9HbIynuV2csLGVLg==", 231 | "dev": true 232 | }, 233 | "node_modules/@types/vscode": { 234 | "version": "1.82.0", 235 | "resolved": "https://registry.npmjs.org/@types/vscode/-/vscode-1.82.0.tgz", 236 | "integrity": "sha512-VSHV+VnpF8DEm8LNrn8OJ8VuUNcBzN3tMvKrNpbhhfuVjFm82+6v44AbDhLvVFgCzn6vs94EJNTp7w8S6+Q1Rw==", 237 | "dev": true 238 | }, 239 | "node_modules/@typescript-eslint/eslint-plugin": { 240 | "version": "5.62.0", 241 | "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.62.0.tgz", 242 | "integrity": "sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag==", 243 | "dev": true, 244 | "dependencies": { 245 | "@eslint-community/regexpp": "^4.4.0", 246 | "@typescript-eslint/scope-manager": "5.62.0", 247 | "@typescript-eslint/type-utils": "5.62.0", 248 | "@typescript-eslint/utils": "5.62.0", 249 | "debug": "^4.3.4", 250 | "graphemer": "^1.4.0", 251 | "ignore": "^5.2.0", 252 | "natural-compare-lite": "^1.4.0", 253 | "semver": "^7.3.7", 254 | "tsutils": "^3.21.0" 255 | }, 256 | "engines": { 257 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 258 | }, 259 | "funding": { 260 | "type": "opencollective", 261 | "url": "https://opencollective.com/typescript-eslint" 262 | }, 263 | "peerDependencies": { 264 | "@typescript-eslint/parser": "^5.0.0", 265 | "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" 266 | }, 267 | "peerDependenciesMeta": { 268 | "typescript": { 269 | "optional": true 270 | } 271 | } 272 | }, 273 | "node_modules/@typescript-eslint/parser": { 274 | "version": "5.62.0", 275 | "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-5.62.0.tgz", 276 | "integrity": "sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA==", 277 | "dev": true, 278 | "dependencies": { 279 | "@typescript-eslint/scope-manager": "5.62.0", 280 | "@typescript-eslint/types": "5.62.0", 281 | "@typescript-eslint/typescript-estree": "5.62.0", 282 | "debug": "^4.3.4" 283 | }, 284 | "engines": { 285 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 286 | }, 287 | "funding": { 288 | "type": "opencollective", 289 | "url": "https://opencollective.com/typescript-eslint" 290 | }, 291 | "peerDependencies": { 292 | "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" 293 | }, 294 | "peerDependenciesMeta": { 295 | "typescript": { 296 | "optional": true 297 | } 298 | } 299 | }, 300 | "node_modules/@typescript-eslint/scope-manager": { 301 | "version": "5.62.0", 302 | "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-5.62.0.tgz", 303 | "integrity": "sha512-VXuvVvZeQCQb5Zgf4HAxc04q5j+WrNAtNh9OwCsCgpKqESMTu3tF/jhZ3xG6T4NZwWl65Bg8KuS2uEvhSfLl0w==", 304 | "dev": true, 305 | "dependencies": { 306 | "@typescript-eslint/types": "5.62.0", 307 | "@typescript-eslint/visitor-keys": "5.62.0" 308 | }, 309 | "engines": { 310 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 311 | }, 312 | "funding": { 313 | "type": "opencollective", 314 | "url": "https://opencollective.com/typescript-eslint" 315 | } 316 | }, 317 | "node_modules/@typescript-eslint/type-utils": { 318 | "version": "5.62.0", 319 | "resolved": "https://registry.npmjs.org/@typescript-eslint/type-utils/-/type-utils-5.62.0.tgz", 320 | "integrity": "sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew==", 321 | "dev": true, 322 | "dependencies": { 323 | "@typescript-eslint/typescript-estree": "5.62.0", 324 | "@typescript-eslint/utils": "5.62.0", 325 | "debug": "^4.3.4", 326 | "tsutils": "^3.21.0" 327 | }, 328 | "engines": { 329 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 330 | }, 331 | "funding": { 332 | "type": "opencollective", 333 | "url": "https://opencollective.com/typescript-eslint" 334 | }, 335 | "peerDependencies": { 336 | "eslint": "*" 337 | }, 338 | "peerDependenciesMeta": { 339 | "typescript": { 340 | "optional": true 341 | } 342 | } 343 | }, 344 | "node_modules/@typescript-eslint/types": { 345 | "version": "5.62.0", 346 | "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-5.62.0.tgz", 347 | "integrity": "sha512-87NVngcbVXUahrRTqIK27gD2t5Cu1yuCXxbLcFtCzZGlfyVWWh8mLHkoxzjsB6DDNnvdL+fW8MiwPEJyGJQDgQ==", 348 | "dev": true, 349 | "engines": { 350 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 351 | }, 352 | "funding": { 353 | "type": "opencollective", 354 | "url": "https://opencollective.com/typescript-eslint" 355 | } 356 | }, 357 | "node_modules/@typescript-eslint/typescript-estree": { 358 | "version": "5.62.0", 359 | "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-5.62.0.tgz", 360 | "integrity": "sha512-CmcQ6uY7b9y694lKdRB8FEel7JbU/40iSAPomu++SjLMntB+2Leay2LO6i8VnJk58MtE9/nQSFIH6jpyRWyYzA==", 361 | "dev": true, 362 | "dependencies": { 363 | "@typescript-eslint/types": "5.62.0", 364 | "@typescript-eslint/visitor-keys": "5.62.0", 365 | "debug": "^4.3.4", 366 | "globby": "^11.1.0", 367 | "is-glob": "^4.0.3", 368 | "semver": "^7.3.7", 369 | "tsutils": "^3.21.0" 370 | }, 371 | "engines": { 372 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 373 | }, 374 | "funding": { 375 | "type": "opencollective", 376 | "url": "https://opencollective.com/typescript-eslint" 377 | }, 378 | "peerDependenciesMeta": { 379 | "typescript": { 380 | "optional": true 381 | } 382 | } 383 | }, 384 | "node_modules/@typescript-eslint/utils": { 385 | "version": "5.62.0", 386 | "resolved": "https://registry.npmjs.org/@typescript-eslint/utils/-/utils-5.62.0.tgz", 387 | "integrity": "sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ==", 388 | "dev": true, 389 | "dependencies": { 390 | "@eslint-community/eslint-utils": "^4.2.0", 391 | "@types/json-schema": "^7.0.9", 392 | "@types/semver": "^7.3.12", 393 | "@typescript-eslint/scope-manager": "5.62.0", 394 | "@typescript-eslint/types": "5.62.0", 395 | "@typescript-eslint/typescript-estree": "5.62.0", 396 | "eslint-scope": "^5.1.1", 397 | "semver": "^7.3.7" 398 | }, 399 | "engines": { 400 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 401 | }, 402 | "funding": { 403 | "type": "opencollective", 404 | "url": "https://opencollective.com/typescript-eslint" 405 | }, 406 | "peerDependencies": { 407 | "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0" 408 | } 409 | }, 410 | "node_modules/@typescript-eslint/visitor-keys": { 411 | "version": "5.62.0", 412 | "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-5.62.0.tgz", 413 | "integrity": "sha512-07ny+LHRzQXepkGg6w0mFY41fVUNBrL2Roj/++7V1txKugfjm/Ci/qSND03r2RhlJhJYMcTn9AhhSSqQp0Ysyw==", 414 | "dev": true, 415 | "dependencies": { 416 | "@typescript-eslint/types": "5.62.0", 417 | "eslint-visitor-keys": "^3.3.0" 418 | }, 419 | "engines": { 420 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 421 | }, 422 | "funding": { 423 | "type": "opencollective", 424 | "url": "https://opencollective.com/typescript-eslint" 425 | } 426 | }, 427 | "node_modules/@vscode/test-electron": { 428 | "version": "2.3.4", 429 | "resolved": "https://registry.npmjs.org/@vscode/test-electron/-/test-electron-2.3.4.tgz", 430 | "integrity": "sha512-eWzIqXMhvlcoXfEFNWrVu/yYT5w6De+WZXR/bafUQhAp8+8GkQo95Oe14phwiRUPv8L+geAKl/QM2+PoT3YW3g==", 431 | "dev": true, 432 | "dependencies": { 433 | "http-proxy-agent": "^4.0.1", 434 | "https-proxy-agent": "^5.0.0", 435 | "jszip": "^3.10.1", 436 | "semver": "^7.5.2" 437 | }, 438 | "engines": { 439 | "node": ">=16" 440 | } 441 | }, 442 | "node_modules/acorn": { 443 | "version": "8.10.0", 444 | "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.10.0.tgz", 445 | "integrity": "sha512-F0SAmZ8iUtS//m8DmCTA0jlh6TDKkHQyK6xc6V4KDTyZKA9dnvX9/3sRTVQrWm79glUAZbnmmNcdYwUIHWVybw==", 446 | "dev": true, 447 | "bin": { 448 | "acorn": "bin/acorn" 449 | }, 450 | "engines": { 451 | "node": ">=0.4.0" 452 | } 453 | }, 454 | "node_modules/acorn-jsx": { 455 | "version": "5.3.2", 456 | "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", 457 | "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", 458 | "dev": true, 459 | "peerDependencies": { 460 | "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" 461 | } 462 | }, 463 | "node_modules/agent-base": { 464 | "version": "6.0.2", 465 | "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-6.0.2.tgz", 466 | "integrity": "sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==", 467 | "dev": true, 468 | "dependencies": { 469 | "debug": "4" 470 | }, 471 | "engines": { 472 | "node": ">= 6.0.0" 473 | } 474 | }, 475 | "node_modules/ajv": { 476 | "version": "6.12.6", 477 | "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.12.6.tgz", 478 | "integrity": "sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==", 479 | "dev": true, 480 | "dependencies": { 481 | "fast-deep-equal": "^3.1.1", 482 | "fast-json-stable-stringify": "^2.0.0", 483 | "json-schema-traverse": "^0.4.1", 484 | "uri-js": "^4.2.2" 485 | }, 486 | "funding": { 487 | "type": "github", 488 | "url": "https://github.com/sponsors/epoberezkin" 489 | } 490 | }, 491 | "node_modules/ansi-colors": { 492 | "version": "4.1.1", 493 | "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz", 494 | "integrity": "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==", 495 | "dev": true, 496 | "engines": { 497 | "node": ">=6" 498 | } 499 | }, 500 | "node_modules/ansi-regex": { 501 | "version": "5.0.1", 502 | "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", 503 | "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", 504 | "dev": true, 505 | "engines": { 506 | "node": ">=8" 507 | } 508 | }, 509 | "node_modules/ansi-styles": { 510 | "version": "4.3.0", 511 | "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", 512 | "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", 513 | "dev": true, 514 | "dependencies": { 515 | "color-convert": "^2.0.1" 516 | }, 517 | "engines": { 518 | "node": ">=8" 519 | }, 520 | "funding": { 521 | "url": "https://github.com/chalk/ansi-styles?sponsor=1" 522 | } 523 | }, 524 | "node_modules/anymatch": { 525 | "version": "3.1.3", 526 | "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", 527 | "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", 528 | "dev": true, 529 | "dependencies": { 530 | "normalize-path": "^3.0.0", 531 | "picomatch": "^2.0.4" 532 | }, 533 | "engines": { 534 | "node": ">= 8" 535 | } 536 | }, 537 | "node_modules/argparse": { 538 | "version": "2.0.1", 539 | "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", 540 | "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", 541 | "dev": true 542 | }, 543 | "node_modules/array-union": { 544 | "version": "2.1.0", 545 | "resolved": "https://registry.npmjs.org/array-union/-/array-union-2.1.0.tgz", 546 | "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", 547 | "dev": true, 548 | "engines": { 549 | "node": ">=8" 550 | } 551 | }, 552 | "node_modules/asynckit": { 553 | "version": "0.4.0", 554 | "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", 555 | "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", 556 | "dev": true 557 | }, 558 | "node_modules/balanced-match": { 559 | "version": "1.0.2", 560 | "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", 561 | "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", 562 | "dev": true 563 | }, 564 | "node_modules/binary-extensions": { 565 | "version": "2.2.0", 566 | "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", 567 | "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", 568 | "dev": true, 569 | "engines": { 570 | "node": ">=8" 571 | } 572 | }, 573 | "node_modules/brace-expansion": { 574 | "version": "1.1.11", 575 | "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", 576 | "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", 577 | "dev": true, 578 | "dependencies": { 579 | "balanced-match": "^1.0.0", 580 | "concat-map": "0.0.1" 581 | } 582 | }, 583 | "node_modules/braces": { 584 | "version": "3.0.2", 585 | "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", 586 | "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", 587 | "dev": true, 588 | "dependencies": { 589 | "fill-range": "^7.0.1" 590 | }, 591 | "engines": { 592 | "node": ">=8" 593 | } 594 | }, 595 | "node_modules/browser-stdout": { 596 | "version": "1.3.1", 597 | "resolved": "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz", 598 | "integrity": "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==", 599 | "dev": true 600 | }, 601 | "node_modules/callsites": { 602 | "version": "3.1.0", 603 | "resolved": "https://registry.npmjs.org/callsites/-/callsites-3.1.0.tgz", 604 | "integrity": "sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==", 605 | "dev": true, 606 | "engines": { 607 | "node": ">=6" 608 | } 609 | }, 610 | "node_modules/camelcase": { 611 | "version": "6.3.0", 612 | "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", 613 | "integrity": "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==", 614 | "dev": true, 615 | "engines": { 616 | "node": ">=10" 617 | }, 618 | "funding": { 619 | "url": "https://github.com/sponsors/sindresorhus" 620 | } 621 | }, 622 | "node_modules/chalk": { 623 | "version": "4.1.2", 624 | "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", 625 | "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", 626 | "dev": true, 627 | "dependencies": { 628 | "ansi-styles": "^4.1.0", 629 | "supports-color": "^7.1.0" 630 | }, 631 | "engines": { 632 | "node": ">=10" 633 | }, 634 | "funding": { 635 | "url": "https://github.com/chalk/chalk?sponsor=1" 636 | } 637 | }, 638 | "node_modules/chokidar": { 639 | "version": "3.5.3", 640 | "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz", 641 | "integrity": "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==", 642 | "dev": true, 643 | "funding": [ 644 | { 645 | "type": "individual", 646 | "url": "https://paulmillr.com/funding/" 647 | } 648 | ], 649 | "dependencies": { 650 | "anymatch": "~3.1.2", 651 | "braces": "~3.0.2", 652 | "glob-parent": "~5.1.2", 653 | "is-binary-path": "~2.1.0", 654 | "is-glob": "~4.0.1", 655 | "normalize-path": "~3.0.0", 656 | "readdirp": "~3.6.0" 657 | }, 658 | "engines": { 659 | "node": ">= 8.10.0" 660 | }, 661 | "optionalDependencies": { 662 | "fsevents": "~2.3.2" 663 | } 664 | }, 665 | "node_modules/chokidar/node_modules/glob-parent": { 666 | "version": "5.1.2", 667 | "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", 668 | "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", 669 | "dev": true, 670 | "dependencies": { 671 | "is-glob": "^4.0.1" 672 | }, 673 | "engines": { 674 | "node": ">= 6" 675 | } 676 | }, 677 | "node_modules/cliui": { 678 | "version": "7.0.4", 679 | "resolved": "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz", 680 | "integrity": "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==", 681 | "dev": true, 682 | "dependencies": { 683 | "string-width": "^4.2.0", 684 | "strip-ansi": "^6.0.0", 685 | "wrap-ansi": "^7.0.0" 686 | } 687 | }, 688 | "node_modules/color-convert": { 689 | "version": "2.0.1", 690 | "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", 691 | "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", 692 | "dev": true, 693 | "dependencies": { 694 | "color-name": "~1.1.4" 695 | }, 696 | "engines": { 697 | "node": ">=7.0.0" 698 | } 699 | }, 700 | "node_modules/color-name": { 701 | "version": "1.1.4", 702 | "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", 703 | "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", 704 | "dev": true 705 | }, 706 | "node_modules/combined-stream": { 707 | "version": "1.0.8", 708 | "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", 709 | "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", 710 | "dev": true, 711 | "dependencies": { 712 | "delayed-stream": "~1.0.0" 713 | }, 714 | "engines": { 715 | "node": ">= 0.8" 716 | } 717 | }, 718 | "node_modules/concat-map": { 719 | "version": "0.0.1", 720 | "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", 721 | "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", 722 | "dev": true 723 | }, 724 | "node_modules/core-util-is": { 725 | "version": "1.0.3", 726 | "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", 727 | "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", 728 | "dev": true 729 | }, 730 | "node_modules/cross-spawn": { 731 | "version": "7.0.3", 732 | "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-7.0.3.tgz", 733 | "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", 734 | "dev": true, 735 | "dependencies": { 736 | "path-key": "^3.1.0", 737 | "shebang-command": "^2.0.0", 738 | "which": "^2.0.1" 739 | }, 740 | "engines": { 741 | "node": ">= 8" 742 | } 743 | }, 744 | "node_modules/debug": { 745 | "version": "4.3.4", 746 | "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", 747 | "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", 748 | "dev": true, 749 | "dependencies": { 750 | "ms": "2.1.2" 751 | }, 752 | "engines": { 753 | "node": ">=6.0" 754 | }, 755 | "peerDependenciesMeta": { 756 | "supports-color": { 757 | "optional": true 758 | } 759 | } 760 | }, 761 | "node_modules/decamelize": { 762 | "version": "4.0.0", 763 | "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-4.0.0.tgz", 764 | "integrity": "sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ==", 765 | "dev": true, 766 | "engines": { 767 | "node": ">=10" 768 | }, 769 | "funding": { 770 | "url": "https://github.com/sponsors/sindresorhus" 771 | } 772 | }, 773 | "node_modules/deep-is": { 774 | "version": "0.1.4", 775 | "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", 776 | "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==", 777 | "dev": true 778 | }, 779 | "node_modules/delayed-stream": { 780 | "version": "1.0.0", 781 | "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", 782 | "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", 783 | "dev": true, 784 | "engines": { 785 | "node": ">=0.4.0" 786 | } 787 | }, 788 | "node_modules/diff": { 789 | "version": "5.0.0", 790 | "resolved": "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz", 791 | "integrity": "sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w==", 792 | "dev": true, 793 | "engines": { 794 | "node": ">=0.3.1" 795 | } 796 | }, 797 | "node_modules/dir-glob": { 798 | "version": "3.0.1", 799 | "resolved": "https://registry.npmjs.org/dir-glob/-/dir-glob-3.0.1.tgz", 800 | "integrity": "sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==", 801 | "dev": true, 802 | "dependencies": { 803 | "path-type": "^4.0.0" 804 | }, 805 | "engines": { 806 | "node": ">=8" 807 | } 808 | }, 809 | "node_modules/doctrine": { 810 | "version": "3.0.0", 811 | "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-3.0.0.tgz", 812 | "integrity": "sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==", 813 | "dev": true, 814 | "dependencies": { 815 | "esutils": "^2.0.2" 816 | }, 817 | "engines": { 818 | "node": ">=6.0.0" 819 | } 820 | }, 821 | "node_modules/emoji-regex": { 822 | "version": "8.0.0", 823 | "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", 824 | "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", 825 | "dev": true 826 | }, 827 | "node_modules/escalade": { 828 | "version": "3.1.1", 829 | "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", 830 | "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", 831 | "dev": true, 832 | "engines": { 833 | "node": ">=6" 834 | } 835 | }, 836 | "node_modules/escape-string-regexp": { 837 | "version": "4.0.0", 838 | "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", 839 | "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", 840 | "dev": true, 841 | "engines": { 842 | "node": ">=10" 843 | }, 844 | "funding": { 845 | "url": "https://github.com/sponsors/sindresorhus" 846 | } 847 | }, 848 | "node_modules/eslint": { 849 | "version": "8.49.0", 850 | "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.49.0.tgz", 851 | "integrity": "sha512-jw03ENfm6VJI0jA9U+8H5zfl5b+FvuU3YYvZRdZHOlU2ggJkxrlkJH4HcDrZpj6YwD8kuYqvQM8LyesoazrSOQ==", 852 | "dev": true, 853 | "dependencies": { 854 | "@eslint-community/eslint-utils": "^4.2.0", 855 | "@eslint-community/regexpp": "^4.6.1", 856 | "@eslint/eslintrc": "^2.1.2", 857 | "@eslint/js": "8.49.0", 858 | "@humanwhocodes/config-array": "^0.11.11", 859 | "@humanwhocodes/module-importer": "^1.0.1", 860 | "@nodelib/fs.walk": "^1.2.8", 861 | "ajv": "^6.12.4", 862 | "chalk": "^4.0.0", 863 | "cross-spawn": "^7.0.2", 864 | "debug": "^4.3.2", 865 | "doctrine": "^3.0.0", 866 | "escape-string-regexp": "^4.0.0", 867 | "eslint-scope": "^7.2.2", 868 | "eslint-visitor-keys": "^3.4.3", 869 | "espree": "^9.6.1", 870 | "esquery": "^1.4.2", 871 | "esutils": "^2.0.2", 872 | "fast-deep-equal": "^3.1.3", 873 | "file-entry-cache": "^6.0.1", 874 | "find-up": "^5.0.0", 875 | "glob-parent": "^6.0.2", 876 | "globals": "^13.19.0", 877 | "graphemer": "^1.4.0", 878 | "ignore": "^5.2.0", 879 | "imurmurhash": "^0.1.4", 880 | "is-glob": "^4.0.0", 881 | "is-path-inside": "^3.0.3", 882 | "js-yaml": "^4.1.0", 883 | "json-stable-stringify-without-jsonify": "^1.0.1", 884 | "levn": "^0.4.1", 885 | "lodash.merge": "^4.6.2", 886 | "minimatch": "^3.1.2", 887 | "natural-compare": "^1.4.0", 888 | "optionator": "^0.9.3", 889 | "strip-ansi": "^6.0.1", 890 | "text-table": "^0.2.0" 891 | }, 892 | "bin": { 893 | "eslint": "bin/eslint.js" 894 | }, 895 | "engines": { 896 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 897 | }, 898 | "funding": { 899 | "url": "https://opencollective.com/eslint" 900 | } 901 | }, 902 | "node_modules/eslint-scope": { 903 | "version": "5.1.1", 904 | "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-5.1.1.tgz", 905 | "integrity": "sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==", 906 | "dev": true, 907 | "dependencies": { 908 | "esrecurse": "^4.3.0", 909 | "estraverse": "^4.1.1" 910 | }, 911 | "engines": { 912 | "node": ">=8.0.0" 913 | } 914 | }, 915 | "node_modules/eslint-visitor-keys": { 916 | "version": "3.4.3", 917 | "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", 918 | "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", 919 | "dev": true, 920 | "engines": { 921 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 922 | }, 923 | "funding": { 924 | "url": "https://opencollective.com/eslint" 925 | } 926 | }, 927 | "node_modules/eslint/node_modules/eslint-scope": { 928 | "version": "7.2.2", 929 | "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.2.tgz", 930 | "integrity": "sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==", 931 | "dev": true, 932 | "dependencies": { 933 | "esrecurse": "^4.3.0", 934 | "estraverse": "^5.2.0" 935 | }, 936 | "engines": { 937 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 938 | }, 939 | "funding": { 940 | "url": "https://opencollective.com/eslint" 941 | } 942 | }, 943 | "node_modules/eslint/node_modules/estraverse": { 944 | "version": "5.3.0", 945 | "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", 946 | "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", 947 | "dev": true, 948 | "engines": { 949 | "node": ">=4.0" 950 | } 951 | }, 952 | "node_modules/espree": { 953 | "version": "9.6.1", 954 | "resolved": "https://registry.npmjs.org/espree/-/espree-9.6.1.tgz", 955 | "integrity": "sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==", 956 | "dev": true, 957 | "dependencies": { 958 | "acorn": "^8.9.0", 959 | "acorn-jsx": "^5.3.2", 960 | "eslint-visitor-keys": "^3.4.1" 961 | }, 962 | "engines": { 963 | "node": "^12.22.0 || ^14.17.0 || >=16.0.0" 964 | }, 965 | "funding": { 966 | "url": "https://opencollective.com/eslint" 967 | } 968 | }, 969 | "node_modules/esquery": { 970 | "version": "1.5.0", 971 | "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.5.0.tgz", 972 | "integrity": "sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==", 973 | "dev": true, 974 | "dependencies": { 975 | "estraverse": "^5.1.0" 976 | }, 977 | "engines": { 978 | "node": ">=0.10" 979 | } 980 | }, 981 | "node_modules/esquery/node_modules/estraverse": { 982 | "version": "5.3.0", 983 | "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", 984 | "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", 985 | "dev": true, 986 | "engines": { 987 | "node": ">=4.0" 988 | } 989 | }, 990 | "node_modules/esrecurse": { 991 | "version": "4.3.0", 992 | "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", 993 | "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", 994 | "dev": true, 995 | "dependencies": { 996 | "estraverse": "^5.2.0" 997 | }, 998 | "engines": { 999 | "node": ">=4.0" 1000 | } 1001 | }, 1002 | "node_modules/esrecurse/node_modules/estraverse": { 1003 | "version": "5.3.0", 1004 | "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", 1005 | "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", 1006 | "dev": true, 1007 | "engines": { 1008 | "node": ">=4.0" 1009 | } 1010 | }, 1011 | "node_modules/estraverse": { 1012 | "version": "4.3.0", 1013 | "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-4.3.0.tgz", 1014 | "integrity": "sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==", 1015 | "dev": true, 1016 | "engines": { 1017 | "node": ">=4.0" 1018 | } 1019 | }, 1020 | "node_modules/esutils": { 1021 | "version": "2.0.3", 1022 | "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", 1023 | "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", 1024 | "dev": true, 1025 | "engines": { 1026 | "node": ">=0.10.0" 1027 | } 1028 | }, 1029 | "node_modules/fast-deep-equal": { 1030 | "version": "3.1.3", 1031 | "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", 1032 | "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", 1033 | "dev": true 1034 | }, 1035 | "node_modules/fast-glob": { 1036 | "version": "3.3.1", 1037 | "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.1.tgz", 1038 | "integrity": "sha512-kNFPyjhh5cKjrUltxs+wFx+ZkbRaxxmZ+X0ZU31SOsxCEtP9VPgtq2teZw1DebupL5GmDaNQ6yKMMVcM41iqDg==", 1039 | "dev": true, 1040 | "dependencies": { 1041 | "@nodelib/fs.stat": "^2.0.2", 1042 | "@nodelib/fs.walk": "^1.2.3", 1043 | "glob-parent": "^5.1.2", 1044 | "merge2": "^1.3.0", 1045 | "micromatch": "^4.0.4" 1046 | }, 1047 | "engines": { 1048 | "node": ">=8.6.0" 1049 | } 1050 | }, 1051 | "node_modules/fast-glob/node_modules/glob-parent": { 1052 | "version": "5.1.2", 1053 | "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", 1054 | "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", 1055 | "dev": true, 1056 | "dependencies": { 1057 | "is-glob": "^4.0.1" 1058 | }, 1059 | "engines": { 1060 | "node": ">= 6" 1061 | } 1062 | }, 1063 | "node_modules/fast-json-stable-stringify": { 1064 | "version": "2.1.0", 1065 | "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", 1066 | "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", 1067 | "dev": true 1068 | }, 1069 | "node_modules/fast-levenshtein": { 1070 | "version": "2.0.6", 1071 | "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", 1072 | "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==", 1073 | "dev": true 1074 | }, 1075 | "node_modules/fastq": { 1076 | "version": "1.15.0", 1077 | "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.15.0.tgz", 1078 | "integrity": "sha512-wBrocU2LCXXa+lWBt8RoIRD89Fi8OdABODa/kEnyeyjS5aZO5/GNvI5sEINADqP/h8M29UHTHUb53sUu5Ihqdw==", 1079 | "dev": true, 1080 | "dependencies": { 1081 | "reusify": "^1.0.4" 1082 | } 1083 | }, 1084 | "node_modules/file-entry-cache": { 1085 | "version": "6.0.1", 1086 | "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-6.0.1.tgz", 1087 | "integrity": "sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==", 1088 | "dev": true, 1089 | "dependencies": { 1090 | "flat-cache": "^3.0.4" 1091 | }, 1092 | "engines": { 1093 | "node": "^10.12.0 || >=12.0.0" 1094 | } 1095 | }, 1096 | "node_modules/fill-range": { 1097 | "version": "7.0.1", 1098 | "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", 1099 | "integrity": "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==", 1100 | "dev": true, 1101 | "dependencies": { 1102 | "to-regex-range": "^5.0.1" 1103 | }, 1104 | "engines": { 1105 | "node": ">=8" 1106 | } 1107 | }, 1108 | "node_modules/find-up": { 1109 | "version": "5.0.0", 1110 | "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", 1111 | "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", 1112 | "dev": true, 1113 | "dependencies": { 1114 | "locate-path": "^6.0.0", 1115 | "path-exists": "^4.0.0" 1116 | }, 1117 | "engines": { 1118 | "node": ">=10" 1119 | }, 1120 | "funding": { 1121 | "url": "https://github.com/sponsors/sindresorhus" 1122 | } 1123 | }, 1124 | "node_modules/flat": { 1125 | "version": "5.0.2", 1126 | "resolved": "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz", 1127 | "integrity": "sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==", 1128 | "dev": true, 1129 | "bin": { 1130 | "flat": "cli.js" 1131 | } 1132 | }, 1133 | "node_modules/flat-cache": { 1134 | "version": "3.1.0", 1135 | "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-3.1.0.tgz", 1136 | "integrity": "sha512-OHx4Qwrrt0E4jEIcI5/Xb+f+QmJYNj2rrK8wiIdQOIrB9WrrJL8cjZvXdXuBTkkEwEqLycb5BeZDV1o2i9bTew==", 1137 | "dev": true, 1138 | "dependencies": { 1139 | "flatted": "^3.2.7", 1140 | "keyv": "^4.5.3", 1141 | "rimraf": "^3.0.2" 1142 | }, 1143 | "engines": { 1144 | "node": ">=12.0.0" 1145 | } 1146 | }, 1147 | "node_modules/flatted": { 1148 | "version": "3.2.7", 1149 | "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.2.7.tgz", 1150 | "integrity": "sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==", 1151 | "dev": true 1152 | }, 1153 | "node_modules/form-data": { 1154 | "version": "3.0.1", 1155 | "resolved": "https://registry.npmjs.org/form-data/-/form-data-3.0.1.tgz", 1156 | "integrity": "sha512-RHkBKtLWUVwd7SqRIvCZMEvAMoGUp0XU+seQiZejj0COz3RI3hWP4sCv3gZWWLjJTd7rGwcsF5eKZGii0r/hbg==", 1157 | "dev": true, 1158 | "dependencies": { 1159 | "asynckit": "^0.4.0", 1160 | "combined-stream": "^1.0.8", 1161 | "mime-types": "^2.1.12" 1162 | }, 1163 | "engines": { 1164 | "node": ">= 6" 1165 | } 1166 | }, 1167 | "node_modules/fs.realpath": { 1168 | "version": "1.0.0", 1169 | "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", 1170 | "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==", 1171 | "dev": true 1172 | }, 1173 | "node_modules/fsevents": { 1174 | "version": "2.3.3", 1175 | "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", 1176 | "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", 1177 | "dev": true, 1178 | "hasInstallScript": true, 1179 | "optional": true, 1180 | "os": [ 1181 | "darwin" 1182 | ], 1183 | "engines": { 1184 | "node": "^8.16.0 || ^10.6.0 || >=11.0.0" 1185 | } 1186 | }, 1187 | "node_modules/get-caller-file": { 1188 | "version": "2.0.5", 1189 | "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", 1190 | "integrity": "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==", 1191 | "dev": true, 1192 | "engines": { 1193 | "node": "6.* || 8.* || >= 10.*" 1194 | } 1195 | }, 1196 | "node_modules/glob": { 1197 | "version": "7.2.3", 1198 | "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", 1199 | "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", 1200 | "dev": true, 1201 | "dependencies": { 1202 | "fs.realpath": "^1.0.0", 1203 | "inflight": "^1.0.4", 1204 | "inherits": "2", 1205 | "minimatch": "^3.1.1", 1206 | "once": "^1.3.0", 1207 | "path-is-absolute": "^1.0.0" 1208 | }, 1209 | "engines": { 1210 | "node": "*" 1211 | }, 1212 | "funding": { 1213 | "url": "https://github.com/sponsors/isaacs" 1214 | } 1215 | }, 1216 | "node_modules/glob-parent": { 1217 | "version": "6.0.2", 1218 | "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", 1219 | "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", 1220 | "dev": true, 1221 | "dependencies": { 1222 | "is-glob": "^4.0.3" 1223 | }, 1224 | "engines": { 1225 | "node": ">=10.13.0" 1226 | } 1227 | }, 1228 | "node_modules/globals": { 1229 | "version": "13.21.0", 1230 | "resolved": "https://registry.npmjs.org/globals/-/globals-13.21.0.tgz", 1231 | "integrity": "sha512-ybyme3s4yy/t/3s35bewwXKOf7cvzfreG2lH0lZl0JB7I4GxRP2ghxOK/Nb9EkRXdbBXZLfq/p/0W2JUONB/Gg==", 1232 | "dev": true, 1233 | "dependencies": { 1234 | "type-fest": "^0.20.2" 1235 | }, 1236 | "engines": { 1237 | "node": ">=8" 1238 | }, 1239 | "funding": { 1240 | "url": "https://github.com/sponsors/sindresorhus" 1241 | } 1242 | }, 1243 | "node_modules/globby": { 1244 | "version": "11.1.0", 1245 | "resolved": "https://registry.npmjs.org/globby/-/globby-11.1.0.tgz", 1246 | "integrity": "sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==", 1247 | "dev": true, 1248 | "dependencies": { 1249 | "array-union": "^2.1.0", 1250 | "dir-glob": "^3.0.1", 1251 | "fast-glob": "^3.2.9", 1252 | "ignore": "^5.2.0", 1253 | "merge2": "^1.4.1", 1254 | "slash": "^3.0.0" 1255 | }, 1256 | "engines": { 1257 | "node": ">=10" 1258 | }, 1259 | "funding": { 1260 | "url": "https://github.com/sponsors/sindresorhus" 1261 | } 1262 | }, 1263 | "node_modules/graphemer": { 1264 | "version": "1.4.0", 1265 | "resolved": "https://registry.npmjs.org/graphemer/-/graphemer-1.4.0.tgz", 1266 | "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==", 1267 | "dev": true 1268 | }, 1269 | "node_modules/has-flag": { 1270 | "version": "4.0.0", 1271 | "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", 1272 | "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", 1273 | "dev": true, 1274 | "engines": { 1275 | "node": ">=8" 1276 | } 1277 | }, 1278 | "node_modules/he": { 1279 | "version": "1.2.0", 1280 | "resolved": "https://registry.npmjs.org/he/-/he-1.2.0.tgz", 1281 | "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", 1282 | "dev": true, 1283 | "bin": { 1284 | "he": "bin/he" 1285 | } 1286 | }, 1287 | "node_modules/http-proxy-agent": { 1288 | "version": "4.0.1", 1289 | "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-4.0.1.tgz", 1290 | "integrity": "sha512-k0zdNgqWTGA6aeIRVpvfVob4fL52dTfaehylg0Y4UvSySvOq/Y+BOyPrgpUrA7HylqvU8vIZGsRuXmspskV0Tg==", 1291 | "dev": true, 1292 | "dependencies": { 1293 | "@tootallnate/once": "1", 1294 | "agent-base": "6", 1295 | "debug": "4" 1296 | }, 1297 | "engines": { 1298 | "node": ">= 6" 1299 | } 1300 | }, 1301 | "node_modules/https-proxy-agent": { 1302 | "version": "5.0.1", 1303 | "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-5.0.1.tgz", 1304 | "integrity": "sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==", 1305 | "dev": true, 1306 | "dependencies": { 1307 | "agent-base": "6", 1308 | "debug": "4" 1309 | }, 1310 | "engines": { 1311 | "node": ">= 6" 1312 | } 1313 | }, 1314 | "node_modules/ignore": { 1315 | "version": "5.2.4", 1316 | "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.2.4.tgz", 1317 | "integrity": "sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ==", 1318 | "dev": true, 1319 | "engines": { 1320 | "node": ">= 4" 1321 | } 1322 | }, 1323 | "node_modules/immediate": { 1324 | "version": "3.0.6", 1325 | "resolved": "https://registry.npmjs.org/immediate/-/immediate-3.0.6.tgz", 1326 | "integrity": "sha512-XXOFtyqDjNDAQxVfYxuF7g9Il/IbWmmlQg2MYKOH8ExIT1qg6xc4zyS3HaEEATgs1btfzxq15ciUiY7gjSXRGQ==", 1327 | "dev": true 1328 | }, 1329 | "node_modules/import-fresh": { 1330 | "version": "3.3.0", 1331 | "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", 1332 | "integrity": "sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==", 1333 | "dev": true, 1334 | "dependencies": { 1335 | "parent-module": "^1.0.0", 1336 | "resolve-from": "^4.0.0" 1337 | }, 1338 | "engines": { 1339 | "node": ">=6" 1340 | }, 1341 | "funding": { 1342 | "url": "https://github.com/sponsors/sindresorhus" 1343 | } 1344 | }, 1345 | "node_modules/imurmurhash": { 1346 | "version": "0.1.4", 1347 | "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", 1348 | "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", 1349 | "dev": true, 1350 | "engines": { 1351 | "node": ">=0.8.19" 1352 | } 1353 | }, 1354 | "node_modules/inflight": { 1355 | "version": "1.0.6", 1356 | "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", 1357 | "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", 1358 | "dev": true, 1359 | "dependencies": { 1360 | "once": "^1.3.0", 1361 | "wrappy": "1" 1362 | } 1363 | }, 1364 | "node_modules/inherits": { 1365 | "version": "2.0.4", 1366 | "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", 1367 | "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", 1368 | "dev": true 1369 | }, 1370 | "node_modules/is-binary-path": { 1371 | "version": "2.1.0", 1372 | "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", 1373 | "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", 1374 | "dev": true, 1375 | "dependencies": { 1376 | "binary-extensions": "^2.0.0" 1377 | }, 1378 | "engines": { 1379 | "node": ">=8" 1380 | } 1381 | }, 1382 | "node_modules/is-extglob": { 1383 | "version": "2.1.1", 1384 | "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", 1385 | "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", 1386 | "dev": true, 1387 | "engines": { 1388 | "node": ">=0.10.0" 1389 | } 1390 | }, 1391 | "node_modules/is-fullwidth-code-point": { 1392 | "version": "3.0.0", 1393 | "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", 1394 | "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", 1395 | "dev": true, 1396 | "engines": { 1397 | "node": ">=8" 1398 | } 1399 | }, 1400 | "node_modules/is-glob": { 1401 | "version": "4.0.3", 1402 | "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", 1403 | "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", 1404 | "dev": true, 1405 | "dependencies": { 1406 | "is-extglob": "^2.1.1" 1407 | }, 1408 | "engines": { 1409 | "node": ">=0.10.0" 1410 | } 1411 | }, 1412 | "node_modules/is-number": { 1413 | "version": "7.0.0", 1414 | "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", 1415 | "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", 1416 | "dev": true, 1417 | "engines": { 1418 | "node": ">=0.12.0" 1419 | } 1420 | }, 1421 | "node_modules/is-path-inside": { 1422 | "version": "3.0.3", 1423 | "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", 1424 | "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", 1425 | "dev": true, 1426 | "engines": { 1427 | "node": ">=8" 1428 | } 1429 | }, 1430 | "node_modules/is-plain-obj": { 1431 | "version": "2.1.0", 1432 | "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz", 1433 | "integrity": "sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==", 1434 | "dev": true, 1435 | "engines": { 1436 | "node": ">=8" 1437 | } 1438 | }, 1439 | "node_modules/is-unicode-supported": { 1440 | "version": "0.1.0", 1441 | "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", 1442 | "integrity": "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==", 1443 | "dev": true, 1444 | "engines": { 1445 | "node": ">=10" 1446 | }, 1447 | "funding": { 1448 | "url": "https://github.com/sponsors/sindresorhus" 1449 | } 1450 | }, 1451 | "node_modules/isarray": { 1452 | "version": "1.0.0", 1453 | "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", 1454 | "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==", 1455 | "dev": true 1456 | }, 1457 | "node_modules/isexe": { 1458 | "version": "2.0.0", 1459 | "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", 1460 | "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", 1461 | "dev": true 1462 | }, 1463 | "node_modules/js-yaml": { 1464 | "version": "4.1.0", 1465 | "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", 1466 | "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", 1467 | "dev": true, 1468 | "dependencies": { 1469 | "argparse": "^2.0.1" 1470 | }, 1471 | "bin": { 1472 | "js-yaml": "bin/js-yaml.js" 1473 | } 1474 | }, 1475 | "node_modules/json-buffer": { 1476 | "version": "3.0.1", 1477 | "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", 1478 | "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==", 1479 | "dev": true 1480 | }, 1481 | "node_modules/json-schema-traverse": { 1482 | "version": "0.4.1", 1483 | "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", 1484 | "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", 1485 | "dev": true 1486 | }, 1487 | "node_modules/json-stable-stringify-without-jsonify": { 1488 | "version": "1.0.1", 1489 | "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", 1490 | "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", 1491 | "dev": true 1492 | }, 1493 | "node_modules/jszip": { 1494 | "version": "3.10.1", 1495 | "resolved": "https://registry.npmjs.org/jszip/-/jszip-3.10.1.tgz", 1496 | "integrity": "sha512-xXDvecyTpGLrqFrvkrUSoxxfJI5AH7U8zxxtVclpsUtMCq4JQ290LY8AW5c7Ggnr/Y/oK+bQMbqK2qmtk3pN4g==", 1497 | "dev": true, 1498 | "dependencies": { 1499 | "lie": "~3.3.0", 1500 | "pako": "~1.0.2", 1501 | "readable-stream": "~2.3.6", 1502 | "setimmediate": "^1.0.5" 1503 | } 1504 | }, 1505 | "node_modules/jszip/node_modules/pako": { 1506 | "version": "1.0.11", 1507 | "resolved": "https://registry.npmjs.org/pako/-/pako-1.0.11.tgz", 1508 | "integrity": "sha512-4hLB8Py4zZce5s4yd9XzopqwVv/yGNhV1Bl8NTmCq1763HeK2+EwVTv+leGeL13Dnh2wfbqowVPXCIO0z4taYw==", 1509 | "dev": true 1510 | }, 1511 | "node_modules/keyv": { 1512 | "version": "4.5.3", 1513 | "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.3.tgz", 1514 | "integrity": "sha512-QCiSav9WaX1PgETJ+SpNnx2PRRapJ/oRSXM4VO5OGYGSjrxbKPVFVhB3l2OCbLCk329N8qyAtsJjSjvVBWzEug==", 1515 | "dev": true, 1516 | "dependencies": { 1517 | "json-buffer": "3.0.1" 1518 | } 1519 | }, 1520 | "node_modules/levn": { 1521 | "version": "0.4.1", 1522 | "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", 1523 | "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", 1524 | "dev": true, 1525 | "dependencies": { 1526 | "prelude-ls": "^1.2.1", 1527 | "type-check": "~0.4.0" 1528 | }, 1529 | "engines": { 1530 | "node": ">= 0.8.0" 1531 | } 1532 | }, 1533 | "node_modules/lie": { 1534 | "version": "3.3.0", 1535 | "resolved": "https://registry.npmjs.org/lie/-/lie-3.3.0.tgz", 1536 | "integrity": "sha512-UaiMJzeWRlEujzAuw5LokY1L5ecNQYZKfmyZ9L7wDHb/p5etKaxXhohBcrw0EYby+G/NA52vRSN4N39dxHAIwQ==", 1537 | "dev": true, 1538 | "dependencies": { 1539 | "immediate": "~3.0.5" 1540 | } 1541 | }, 1542 | "node_modules/locate-path": { 1543 | "version": "6.0.0", 1544 | "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", 1545 | "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", 1546 | "dev": true, 1547 | "dependencies": { 1548 | "p-locate": "^5.0.0" 1549 | }, 1550 | "engines": { 1551 | "node": ">=10" 1552 | }, 1553 | "funding": { 1554 | "url": "https://github.com/sponsors/sindresorhus" 1555 | } 1556 | }, 1557 | "node_modules/lodash.merge": { 1558 | "version": "4.6.2", 1559 | "resolved": "https://registry.npmjs.org/lodash.merge/-/lodash.merge-4.6.2.tgz", 1560 | "integrity": "sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==", 1561 | "dev": true 1562 | }, 1563 | "node_modules/log-symbols": { 1564 | "version": "4.1.0", 1565 | "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", 1566 | "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", 1567 | "dev": true, 1568 | "dependencies": { 1569 | "chalk": "^4.1.0", 1570 | "is-unicode-supported": "^0.1.0" 1571 | }, 1572 | "engines": { 1573 | "node": ">=10" 1574 | }, 1575 | "funding": { 1576 | "url": "https://github.com/sponsors/sindresorhus" 1577 | } 1578 | }, 1579 | "node_modules/lru-cache": { 1580 | "version": "6.0.0", 1581 | "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", 1582 | "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", 1583 | "dev": true, 1584 | "dependencies": { 1585 | "yallist": "^4.0.0" 1586 | }, 1587 | "engines": { 1588 | "node": ">=10" 1589 | } 1590 | }, 1591 | "node_modules/merge2": { 1592 | "version": "1.4.1", 1593 | "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", 1594 | "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", 1595 | "dev": true, 1596 | "engines": { 1597 | "node": ">= 8" 1598 | } 1599 | }, 1600 | "node_modules/micromatch": { 1601 | "version": "4.0.5", 1602 | "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.5.tgz", 1603 | "integrity": "sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==", 1604 | "dev": true, 1605 | "dependencies": { 1606 | "braces": "^3.0.2", 1607 | "picomatch": "^2.3.1" 1608 | }, 1609 | "engines": { 1610 | "node": ">=8.6" 1611 | } 1612 | }, 1613 | "node_modules/mime-db": { 1614 | "version": "1.52.0", 1615 | "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", 1616 | "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", 1617 | "dev": true, 1618 | "engines": { 1619 | "node": ">= 0.6" 1620 | } 1621 | }, 1622 | "node_modules/mime-types": { 1623 | "version": "2.1.35", 1624 | "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", 1625 | "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", 1626 | "dev": true, 1627 | "dependencies": { 1628 | "mime-db": "1.52.0" 1629 | }, 1630 | "engines": { 1631 | "node": ">= 0.6" 1632 | } 1633 | }, 1634 | "node_modules/minimatch": { 1635 | "version": "3.1.2", 1636 | "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", 1637 | "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", 1638 | "dev": true, 1639 | "dependencies": { 1640 | "brace-expansion": "^1.1.7" 1641 | }, 1642 | "engines": { 1643 | "node": "*" 1644 | } 1645 | }, 1646 | "node_modules/mocha": { 1647 | "version": "10.2.0", 1648 | "resolved": "https://registry.npmjs.org/mocha/-/mocha-10.2.0.tgz", 1649 | "integrity": "sha512-IDY7fl/BecMwFHzoqF2sg/SHHANeBoMMXFlS9r0OXKDssYE1M5O43wUY/9BVPeIvfH2zmEbBfseqN9gBQZzXkg==", 1650 | "dev": true, 1651 | "dependencies": { 1652 | "ansi-colors": "4.1.1", 1653 | "browser-stdout": "1.3.1", 1654 | "chokidar": "3.5.3", 1655 | "debug": "4.3.4", 1656 | "diff": "5.0.0", 1657 | "escape-string-regexp": "4.0.0", 1658 | "find-up": "5.0.0", 1659 | "glob": "7.2.0", 1660 | "he": "1.2.0", 1661 | "js-yaml": "4.1.0", 1662 | "log-symbols": "4.1.0", 1663 | "minimatch": "5.0.1", 1664 | "ms": "2.1.3", 1665 | "nanoid": "3.3.3", 1666 | "serialize-javascript": "6.0.0", 1667 | "strip-json-comments": "3.1.1", 1668 | "supports-color": "8.1.1", 1669 | "workerpool": "6.2.1", 1670 | "yargs": "16.2.0", 1671 | "yargs-parser": "20.2.4", 1672 | "yargs-unparser": "2.0.0" 1673 | }, 1674 | "bin": { 1675 | "_mocha": "bin/_mocha", 1676 | "mocha": "bin/mocha.js" 1677 | }, 1678 | "engines": { 1679 | "node": ">= 14.0.0" 1680 | }, 1681 | "funding": { 1682 | "type": "opencollective", 1683 | "url": "https://opencollective.com/mochajs" 1684 | } 1685 | }, 1686 | "node_modules/mocha/node_modules/glob": { 1687 | "version": "7.2.0", 1688 | "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", 1689 | "integrity": "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==", 1690 | "dev": true, 1691 | "dependencies": { 1692 | "fs.realpath": "^1.0.0", 1693 | "inflight": "^1.0.4", 1694 | "inherits": "2", 1695 | "minimatch": "^3.0.4", 1696 | "once": "^1.3.0", 1697 | "path-is-absolute": "^1.0.0" 1698 | }, 1699 | "engines": { 1700 | "node": "*" 1701 | }, 1702 | "funding": { 1703 | "url": "https://github.com/sponsors/isaacs" 1704 | } 1705 | }, 1706 | "node_modules/mocha/node_modules/glob/node_modules/minimatch": { 1707 | "version": "3.1.2", 1708 | "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", 1709 | "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", 1710 | "dev": true, 1711 | "dependencies": { 1712 | "brace-expansion": "^1.1.7" 1713 | }, 1714 | "engines": { 1715 | "node": "*" 1716 | } 1717 | }, 1718 | "node_modules/mocha/node_modules/minimatch": { 1719 | "version": "5.0.1", 1720 | "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-5.0.1.tgz", 1721 | "integrity": "sha512-nLDxIFRyhDblz3qMuq+SoRZED4+miJ/G+tdDrjkkkRnjAsBexeGpgjLEQ0blJy7rHhR2b93rhQY4SvyWu9v03g==", 1722 | "dev": true, 1723 | "dependencies": { 1724 | "brace-expansion": "^2.0.1" 1725 | }, 1726 | "engines": { 1727 | "node": ">=10" 1728 | } 1729 | }, 1730 | "node_modules/mocha/node_modules/minimatch/node_modules/brace-expansion": { 1731 | "version": "2.0.1", 1732 | "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz", 1733 | "integrity": "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==", 1734 | "dev": true, 1735 | "dependencies": { 1736 | "balanced-match": "^1.0.0" 1737 | } 1738 | }, 1739 | "node_modules/mocha/node_modules/ms": { 1740 | "version": "2.1.3", 1741 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", 1742 | "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", 1743 | "dev": true 1744 | }, 1745 | "node_modules/mocha/node_modules/supports-color": { 1746 | "version": "8.1.1", 1747 | "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", 1748 | "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", 1749 | "dev": true, 1750 | "dependencies": { 1751 | "has-flag": "^4.0.0" 1752 | }, 1753 | "engines": { 1754 | "node": ">=10" 1755 | }, 1756 | "funding": { 1757 | "url": "https://github.com/chalk/supports-color?sponsor=1" 1758 | } 1759 | }, 1760 | "node_modules/ms": { 1761 | "version": "2.1.2", 1762 | "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", 1763 | "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==", 1764 | "dev": true 1765 | }, 1766 | "node_modules/nanoid": { 1767 | "version": "3.3.3", 1768 | "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.3.tgz", 1769 | "integrity": "sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w==", 1770 | "dev": true, 1771 | "bin": { 1772 | "nanoid": "bin/nanoid.cjs" 1773 | }, 1774 | "engines": { 1775 | "node": "^10 || ^12 || ^13.7 || ^14 || >=15.0.1" 1776 | } 1777 | }, 1778 | "node_modules/natural-compare": { 1779 | "version": "1.4.0", 1780 | "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", 1781 | "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", 1782 | "dev": true 1783 | }, 1784 | "node_modules/natural-compare-lite": { 1785 | "version": "1.4.0", 1786 | "resolved": "https://registry.npmjs.org/natural-compare-lite/-/natural-compare-lite-1.4.0.tgz", 1787 | "integrity": "sha512-Tj+HTDSJJKaZnfiuw+iaF9skdPpTo2GtEly5JHnWV/hfv2Qj/9RKsGISQtLh2ox3l5EAGw487hnBee0sIJ6v2g==", 1788 | "dev": true 1789 | }, 1790 | "node_modules/node-fetch": { 1791 | "version": "2.7.0", 1792 | "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", 1793 | "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", 1794 | "dependencies": { 1795 | "whatwg-url": "^5.0.0" 1796 | }, 1797 | "engines": { 1798 | "node": "4.x || >=6.0.0" 1799 | }, 1800 | "peerDependencies": { 1801 | "encoding": "^0.1.0" 1802 | }, 1803 | "peerDependenciesMeta": { 1804 | "encoding": { 1805 | "optional": true 1806 | } 1807 | } 1808 | }, 1809 | "node_modules/normalize-path": { 1810 | "version": "3.0.0", 1811 | "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", 1812 | "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", 1813 | "dev": true, 1814 | "engines": { 1815 | "node": ">=0.10.0" 1816 | } 1817 | }, 1818 | "node_modules/once": { 1819 | "version": "1.4.0", 1820 | "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", 1821 | "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", 1822 | "dev": true, 1823 | "dependencies": { 1824 | "wrappy": "1" 1825 | } 1826 | }, 1827 | "node_modules/optionator": { 1828 | "version": "0.9.3", 1829 | "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.3.tgz", 1830 | "integrity": "sha512-JjCoypp+jKn1ttEFExxhetCKeJt9zhAgAve5FXHixTvFDW/5aEktX9bufBKLRRMdU7bNtpLfcGu94B3cdEJgjg==", 1831 | "dev": true, 1832 | "dependencies": { 1833 | "@aashutoshrathi/word-wrap": "^1.2.3", 1834 | "deep-is": "^0.1.3", 1835 | "fast-levenshtein": "^2.0.6", 1836 | "levn": "^0.4.1", 1837 | "prelude-ls": "^1.2.1", 1838 | "type-check": "^0.4.0" 1839 | }, 1840 | "engines": { 1841 | "node": ">= 0.8.0" 1842 | } 1843 | }, 1844 | "node_modules/p-limit": { 1845 | "version": "3.1.0", 1846 | "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", 1847 | "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", 1848 | "dev": true, 1849 | "dependencies": { 1850 | "yocto-queue": "^0.1.0" 1851 | }, 1852 | "engines": { 1853 | "node": ">=10" 1854 | }, 1855 | "funding": { 1856 | "url": "https://github.com/sponsors/sindresorhus" 1857 | } 1858 | }, 1859 | "node_modules/p-locate": { 1860 | "version": "5.0.0", 1861 | "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", 1862 | "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", 1863 | "dev": true, 1864 | "dependencies": { 1865 | "p-limit": "^3.0.2" 1866 | }, 1867 | "engines": { 1868 | "node": ">=10" 1869 | }, 1870 | "funding": { 1871 | "url": "https://github.com/sponsors/sindresorhus" 1872 | } 1873 | }, 1874 | "node_modules/pako": { 1875 | "version": "2.1.0", 1876 | "resolved": "https://registry.npmjs.org/pako/-/pako-2.1.0.tgz", 1877 | "integrity": "sha512-w+eufiZ1WuJYgPXbV/PO3NCMEc3xqylkKHzp8bxp1uW4qaSNQUkwmLLEc3kKsfz8lpV1F8Ht3U1Cm+9Srog2ug==" 1878 | }, 1879 | "node_modules/parent-module": { 1880 | "version": "1.0.1", 1881 | "resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz", 1882 | "integrity": "sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==", 1883 | "dev": true, 1884 | "dependencies": { 1885 | "callsites": "^3.0.0" 1886 | }, 1887 | "engines": { 1888 | "node": ">=6" 1889 | } 1890 | }, 1891 | "node_modules/path-exists": { 1892 | "version": "4.0.0", 1893 | "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", 1894 | "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", 1895 | "dev": true, 1896 | "engines": { 1897 | "node": ">=8" 1898 | } 1899 | }, 1900 | "node_modules/path-is-absolute": { 1901 | "version": "1.0.1", 1902 | "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", 1903 | "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", 1904 | "dev": true, 1905 | "engines": { 1906 | "node": ">=0.10.0" 1907 | } 1908 | }, 1909 | "node_modules/path-key": { 1910 | "version": "3.1.1", 1911 | "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", 1912 | "integrity": "sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==", 1913 | "dev": true, 1914 | "engines": { 1915 | "node": ">=8" 1916 | } 1917 | }, 1918 | "node_modules/path-type": { 1919 | "version": "4.0.0", 1920 | "resolved": "https://registry.npmjs.org/path-type/-/path-type-4.0.0.tgz", 1921 | "integrity": "sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==", 1922 | "dev": true, 1923 | "engines": { 1924 | "node": ">=8" 1925 | } 1926 | }, 1927 | "node_modules/picomatch": { 1928 | "version": "2.3.1", 1929 | "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", 1930 | "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", 1931 | "dev": true, 1932 | "engines": { 1933 | "node": ">=8.6" 1934 | }, 1935 | "funding": { 1936 | "url": "https://github.com/sponsors/jonschlinkert" 1937 | } 1938 | }, 1939 | "node_modules/prelude-ls": { 1940 | "version": "1.2.1", 1941 | "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", 1942 | "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==", 1943 | "dev": true, 1944 | "engines": { 1945 | "node": ">= 0.8.0" 1946 | } 1947 | }, 1948 | "node_modules/process-nextick-args": { 1949 | "version": "2.0.1", 1950 | "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", 1951 | "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", 1952 | "dev": true 1953 | }, 1954 | "node_modules/punycode": { 1955 | "version": "2.3.0", 1956 | "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.0.tgz", 1957 | "integrity": "sha512-rRV+zQD8tVFys26lAGR9WUuS4iUAngJScM+ZRSKtvl5tKeZ2t5bvdNFdNHBW9FWR4guGHlgmsZ1G7BSm2wTbuA==", 1958 | "dev": true, 1959 | "engines": { 1960 | "node": ">=6" 1961 | } 1962 | }, 1963 | "node_modules/queue-microtask": { 1964 | "version": "1.2.3", 1965 | "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", 1966 | "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", 1967 | "dev": true, 1968 | "funding": [ 1969 | { 1970 | "type": "github", 1971 | "url": "https://github.com/sponsors/feross" 1972 | }, 1973 | { 1974 | "type": "patreon", 1975 | "url": "https://www.patreon.com/feross" 1976 | }, 1977 | { 1978 | "type": "consulting", 1979 | "url": "https://feross.org/support" 1980 | } 1981 | ] 1982 | }, 1983 | "node_modules/randombytes": { 1984 | "version": "2.1.0", 1985 | "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", 1986 | "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", 1987 | "dev": true, 1988 | "dependencies": { 1989 | "safe-buffer": "^5.1.0" 1990 | } 1991 | }, 1992 | "node_modules/readable-stream": { 1993 | "version": "2.3.8", 1994 | "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", 1995 | "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", 1996 | "dev": true, 1997 | "dependencies": { 1998 | "core-util-is": "~1.0.0", 1999 | "inherits": "~2.0.3", 2000 | "isarray": "~1.0.0", 2001 | "process-nextick-args": "~2.0.0", 2002 | "safe-buffer": "~5.1.1", 2003 | "string_decoder": "~1.1.1", 2004 | "util-deprecate": "~1.0.1" 2005 | } 2006 | }, 2007 | "node_modules/readdirp": { 2008 | "version": "3.6.0", 2009 | "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", 2010 | "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", 2011 | "dev": true, 2012 | "dependencies": { 2013 | "picomatch": "^2.2.1" 2014 | }, 2015 | "engines": { 2016 | "node": ">=8.10.0" 2017 | } 2018 | }, 2019 | "node_modules/require-directory": { 2020 | "version": "2.1.1", 2021 | "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", 2022 | "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", 2023 | "dev": true, 2024 | "engines": { 2025 | "node": ">=0.10.0" 2026 | } 2027 | }, 2028 | "node_modules/resolve-from": { 2029 | "version": "4.0.0", 2030 | "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-4.0.0.tgz", 2031 | "integrity": "sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==", 2032 | "dev": true, 2033 | "engines": { 2034 | "node": ">=4" 2035 | } 2036 | }, 2037 | "node_modules/reusify": { 2038 | "version": "1.0.4", 2039 | "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.0.4.tgz", 2040 | "integrity": "sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==", 2041 | "dev": true, 2042 | "engines": { 2043 | "iojs": ">=1.0.0", 2044 | "node": ">=0.10.0" 2045 | } 2046 | }, 2047 | "node_modules/rimraf": { 2048 | "version": "3.0.2", 2049 | "resolved": "https://registry.npmjs.org/rimraf/-/rimraf-3.0.2.tgz", 2050 | "integrity": "sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==", 2051 | "dev": true, 2052 | "dependencies": { 2053 | "glob": "^7.1.3" 2054 | }, 2055 | "bin": { 2056 | "rimraf": "bin.js" 2057 | }, 2058 | "funding": { 2059 | "url": "https://github.com/sponsors/isaacs" 2060 | } 2061 | }, 2062 | "node_modules/run-parallel": { 2063 | "version": "1.2.0", 2064 | "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", 2065 | "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", 2066 | "dev": true, 2067 | "funding": [ 2068 | { 2069 | "type": "github", 2070 | "url": "https://github.com/sponsors/feross" 2071 | }, 2072 | { 2073 | "type": "patreon", 2074 | "url": "https://www.patreon.com/feross" 2075 | }, 2076 | { 2077 | "type": "consulting", 2078 | "url": "https://feross.org/support" 2079 | } 2080 | ], 2081 | "dependencies": { 2082 | "queue-microtask": "^1.2.2" 2083 | } 2084 | }, 2085 | "node_modules/safe-buffer": { 2086 | "version": "5.1.2", 2087 | "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", 2088 | "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", 2089 | "dev": true 2090 | }, 2091 | "node_modules/semver": { 2092 | "version": "7.5.4", 2093 | "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", 2094 | "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", 2095 | "dev": true, 2096 | "dependencies": { 2097 | "lru-cache": "^6.0.0" 2098 | }, 2099 | "bin": { 2100 | "semver": "bin/semver.js" 2101 | }, 2102 | "engines": { 2103 | "node": ">=10" 2104 | } 2105 | }, 2106 | "node_modules/serialize-javascript": { 2107 | "version": "6.0.0", 2108 | "resolved": "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.0.tgz", 2109 | "integrity": "sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==", 2110 | "dev": true, 2111 | "dependencies": { 2112 | "randombytes": "^2.1.0" 2113 | } 2114 | }, 2115 | "node_modules/setimmediate": { 2116 | "version": "1.0.5", 2117 | "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", 2118 | "integrity": "sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==", 2119 | "dev": true 2120 | }, 2121 | "node_modules/shebang-command": { 2122 | "version": "2.0.0", 2123 | "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-2.0.0.tgz", 2124 | "integrity": "sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==", 2125 | "dev": true, 2126 | "dependencies": { 2127 | "shebang-regex": "^3.0.0" 2128 | }, 2129 | "engines": { 2130 | "node": ">=8" 2131 | } 2132 | }, 2133 | "node_modules/shebang-regex": { 2134 | "version": "3.0.0", 2135 | "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-3.0.0.tgz", 2136 | "integrity": "sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==", 2137 | "dev": true, 2138 | "engines": { 2139 | "node": ">=8" 2140 | } 2141 | }, 2142 | "node_modules/slash": { 2143 | "version": "3.0.0", 2144 | "resolved": "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz", 2145 | "integrity": "sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==", 2146 | "dev": true, 2147 | "engines": { 2148 | "node": ">=8" 2149 | } 2150 | }, 2151 | "node_modules/string_decoder": { 2152 | "version": "1.1.1", 2153 | "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", 2154 | "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", 2155 | "dev": true, 2156 | "dependencies": { 2157 | "safe-buffer": "~5.1.0" 2158 | } 2159 | }, 2160 | "node_modules/string-width": { 2161 | "version": "4.2.3", 2162 | "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", 2163 | "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", 2164 | "dev": true, 2165 | "dependencies": { 2166 | "emoji-regex": "^8.0.0", 2167 | "is-fullwidth-code-point": "^3.0.0", 2168 | "strip-ansi": "^6.0.1" 2169 | }, 2170 | "engines": { 2171 | "node": ">=8" 2172 | } 2173 | }, 2174 | "node_modules/strip-ansi": { 2175 | "version": "6.0.1", 2176 | "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", 2177 | "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", 2178 | "dev": true, 2179 | "dependencies": { 2180 | "ansi-regex": "^5.0.1" 2181 | }, 2182 | "engines": { 2183 | "node": ">=8" 2184 | } 2185 | }, 2186 | "node_modules/strip-json-comments": { 2187 | "version": "3.1.1", 2188 | "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz", 2189 | "integrity": "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==", 2190 | "dev": true, 2191 | "engines": { 2192 | "node": ">=8" 2193 | }, 2194 | "funding": { 2195 | "url": "https://github.com/sponsors/sindresorhus" 2196 | } 2197 | }, 2198 | "node_modules/supports-color": { 2199 | "version": "7.2.0", 2200 | "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", 2201 | "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", 2202 | "dev": true, 2203 | "dependencies": { 2204 | "has-flag": "^4.0.0" 2205 | }, 2206 | "engines": { 2207 | "node": ">=8" 2208 | } 2209 | }, 2210 | "node_modules/text-table": { 2211 | "version": "0.2.0", 2212 | "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", 2213 | "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==", 2214 | "dev": true 2215 | }, 2216 | "node_modules/to-regex-range": { 2217 | "version": "5.0.1", 2218 | "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", 2219 | "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", 2220 | "dev": true, 2221 | "dependencies": { 2222 | "is-number": "^7.0.0" 2223 | }, 2224 | "engines": { 2225 | "node": ">=8.0" 2226 | } 2227 | }, 2228 | "node_modules/tr46": { 2229 | "version": "0.0.3", 2230 | "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", 2231 | "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" 2232 | }, 2233 | "node_modules/tslib": { 2234 | "version": "1.14.1", 2235 | "resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz", 2236 | "integrity": "sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==", 2237 | "dev": true 2238 | }, 2239 | "node_modules/tsutils": { 2240 | "version": "3.21.0", 2241 | "resolved": "https://registry.npmjs.org/tsutils/-/tsutils-3.21.0.tgz", 2242 | "integrity": "sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA==", 2243 | "dev": true, 2244 | "dependencies": { 2245 | "tslib": "^1.8.1" 2246 | }, 2247 | "engines": { 2248 | "node": ">= 6" 2249 | }, 2250 | "peerDependencies": { 2251 | "typescript": ">=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta" 2252 | } 2253 | }, 2254 | "node_modules/type-check": { 2255 | "version": "0.4.0", 2256 | "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", 2257 | "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==", 2258 | "dev": true, 2259 | "dependencies": { 2260 | "prelude-ls": "^1.2.1" 2261 | }, 2262 | "engines": { 2263 | "node": ">= 0.8.0" 2264 | } 2265 | }, 2266 | "node_modules/type-fest": { 2267 | "version": "0.20.2", 2268 | "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", 2269 | "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", 2270 | "dev": true, 2271 | "engines": { 2272 | "node": ">=10" 2273 | }, 2274 | "funding": { 2275 | "url": "https://github.com/sponsors/sindresorhus" 2276 | } 2277 | }, 2278 | "node_modules/typescript": { 2279 | "version": "4.9.5", 2280 | "resolved": "https://registry.npmjs.org/typescript/-/typescript-4.9.5.tgz", 2281 | "integrity": "sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==", 2282 | "dev": true, 2283 | "bin": { 2284 | "tsc": "bin/tsc", 2285 | "tsserver": "bin/tsserver" 2286 | }, 2287 | "engines": { 2288 | "node": ">=4.2.0" 2289 | } 2290 | }, 2291 | "node_modules/uri-js": { 2292 | "version": "4.4.1", 2293 | "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", 2294 | "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", 2295 | "dev": true, 2296 | "dependencies": { 2297 | "punycode": "^2.1.0" 2298 | } 2299 | }, 2300 | "node_modules/util-deprecate": { 2301 | "version": "1.0.2", 2302 | "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", 2303 | "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", 2304 | "dev": true 2305 | }, 2306 | "node_modules/web-tree-sitter": { 2307 | "version": "0.20.8", 2308 | "resolved": "https://registry.npmjs.org/web-tree-sitter/-/web-tree-sitter-0.20.8.tgz", 2309 | "integrity": "sha512-weOVgZ3aAARgdnb220GqYuh7+rZU0Ka9k9yfKtGAzEYMa6GgiCzW9JjQRJyCJakvibQW+dfjJdihjInKuuCAUQ==" 2310 | }, 2311 | "node_modules/webidl-conversions": { 2312 | "version": "3.0.1", 2313 | "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", 2314 | "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" 2315 | }, 2316 | "node_modules/whatwg-url": { 2317 | "version": "5.0.0", 2318 | "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", 2319 | "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", 2320 | "dependencies": { 2321 | "tr46": "~0.0.3", 2322 | "webidl-conversions": "^3.0.0" 2323 | } 2324 | }, 2325 | "node_modules/which": { 2326 | "version": "2.0.2", 2327 | "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", 2328 | "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", 2329 | "dev": true, 2330 | "dependencies": { 2331 | "isexe": "^2.0.0" 2332 | }, 2333 | "bin": { 2334 | "node-which": "bin/node-which" 2335 | }, 2336 | "engines": { 2337 | "node": ">= 8" 2338 | } 2339 | }, 2340 | "node_modules/workerpool": { 2341 | "version": "6.2.1", 2342 | "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.2.1.tgz", 2343 | "integrity": "sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw==", 2344 | "dev": true 2345 | }, 2346 | "node_modules/wrap-ansi": { 2347 | "version": "7.0.0", 2348 | "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz", 2349 | "integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==", 2350 | "dev": true, 2351 | "dependencies": { 2352 | "ansi-styles": "^4.0.0", 2353 | "string-width": "^4.1.0", 2354 | "strip-ansi": "^6.0.0" 2355 | }, 2356 | "engines": { 2357 | "node": ">=10" 2358 | }, 2359 | "funding": { 2360 | "url": "https://github.com/chalk/wrap-ansi?sponsor=1" 2361 | } 2362 | }, 2363 | "node_modules/wrappy": { 2364 | "version": "1.0.2", 2365 | "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", 2366 | "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", 2367 | "dev": true 2368 | }, 2369 | "node_modules/y18n": { 2370 | "version": "5.0.8", 2371 | "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", 2372 | "integrity": "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==", 2373 | "dev": true, 2374 | "engines": { 2375 | "node": ">=10" 2376 | } 2377 | }, 2378 | "node_modules/yallist": { 2379 | "version": "4.0.0", 2380 | "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", 2381 | "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", 2382 | "dev": true 2383 | }, 2384 | "node_modules/yargs": { 2385 | "version": "16.2.0", 2386 | "resolved": "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz", 2387 | "integrity": "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==", 2388 | "dev": true, 2389 | "dependencies": { 2390 | "cliui": "^7.0.2", 2391 | "escalade": "^3.1.1", 2392 | "get-caller-file": "^2.0.5", 2393 | "require-directory": "^2.1.1", 2394 | "string-width": "^4.2.0", 2395 | "y18n": "^5.0.5", 2396 | "yargs-parser": "^20.2.2" 2397 | }, 2398 | "engines": { 2399 | "node": ">=10" 2400 | } 2401 | }, 2402 | "node_modules/yargs-parser": { 2403 | "version": "20.2.4", 2404 | "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.4.tgz", 2405 | "integrity": "sha512-WOkpgNhPTlE73h4VFAFsOnomJVaovO8VqLDzy5saChRBFQFBoMYirowyW+Q9HB4HFF4Z7VZTiG3iSzJJA29yRA==", 2406 | "dev": true, 2407 | "engines": { 2408 | "node": ">=10" 2409 | } 2410 | }, 2411 | "node_modules/yargs-unparser": { 2412 | "version": "2.0.0", 2413 | "resolved": "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-2.0.0.tgz", 2414 | "integrity": "sha512-7pRTIA9Qc1caZ0bZ6RYRGbHJthJWuakf+WmHK0rVeLkNrrGhfoabBNdue6kdINI6r4if7ocq9aD/n7xwKOdzOA==", 2415 | "dev": true, 2416 | "dependencies": { 2417 | "camelcase": "^6.0.0", 2418 | "decamelize": "^4.0.0", 2419 | "flat": "^5.0.2", 2420 | "is-plain-obj": "^2.1.0" 2421 | }, 2422 | "engines": { 2423 | "node": ">=10" 2424 | } 2425 | }, 2426 | "node_modules/yocto-queue": { 2427 | "version": "0.1.0", 2428 | "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", 2429 | "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", 2430 | "dev": true, 2431 | "engines": { 2432 | "node": ">=10" 2433 | }, 2434 | "funding": { 2435 | "url": "https://github.com/sponsors/sindresorhus" 2436 | } 2437 | } 2438 | } 2439 | } 2440 | -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "vscode-h2o", 3 | "displayName": "Shell Script Command Completion", 4 | "version": "0.2.14", 5 | "description": "Add CLI autocomplete to shell script", 6 | "repository": { 7 | "url": "https://github.com/yamaton/vscode-h2o" 8 | }, 9 | "publisher": "tetradresearch", 10 | "author": { 11 | "name": "Yamato Matsuoka", 12 | "email": "yamato.matsuoka@tritonlab.io" 13 | }, 14 | "license": "MIT", 15 | "engines": { 16 | "vscode": "^1.63.0" 17 | }, 18 | "categories": [ 19 | "Snippets" 20 | ], 21 | "icon": "images/animal_chara_computer_penguin.png", 22 | "keywords": [ 23 | "shellscript", 24 | "completion", 25 | "autocomplete", 26 | "intellisense", 27 | "cli", 28 | "bioinformatics", 29 | "man", 30 | "shell", 31 | "bash", 32 | "h2o" 33 | ], 34 | "activationEvents": [ 35 | "onLanguage:shellscript" 36 | ], 37 | "main": "./out/extension.js", 38 | "contributes": { 39 | "commands": [ 40 | { 41 | "command": "h2o.clearCache", 42 | "title": "Shell Completion: Remove Command Spec" 43 | }, 44 | { 45 | "command": "h2o.loadCommon", 46 | "title": "Shell Completion: Load All Common CLI Specs" 47 | }, 48 | { 49 | "command": "h2o.loadBio", 50 | "title": "Shell Completion: Load All Bioinformatics CLI Specs" 51 | }, 52 | { 53 | "command": "h2o.removeBio", 54 | "title": "Shell Completion: Remove All Bioinformatics CLI Specs" 55 | }, 56 | { 57 | "command": "h2o.loadCommand", 58 | "title": "Shell Completion: Load Command Spec (experimental)" 59 | }, 60 | { 61 | "command": "registeredCommands.refreshEntry", 62 | "title": "Refresh", 63 | "icon": "$(refresh)" 64 | }, 65 | { 66 | "command": "registeredCommands.removeEntry", 67 | "title": "Remove", 68 | "icon": "$(trash)" 69 | } 70 | ], 71 | "menus": { 72 | "commandPalette": [ 73 | { 74 | "command": "h2o.clearCache", 75 | "when": "editorLangId == shellscript" 76 | }, 77 | { 78 | "command": "h2o.loadCommon", 79 | "when": "editorLangId == shellscript" 80 | }, 81 | { 82 | "command": "h2o.loadBio", 83 | "when": "editorLangId == shellscript" 84 | }, 85 | { 86 | "command": "h2o.removeBio", 87 | "when": "editorLangId == shellscript" 88 | }, 89 | { 90 | "command": "h2o.loadCommand", 91 | "when": "editorLangId == shellscript" 92 | } 93 | ], 94 | "view/title": [ 95 | { 96 | "command": "registeredCommands.refreshEntry", 97 | "when": "view == registeredCommands", 98 | "group": "navigation" 99 | } 100 | ], 101 | "view/item/context": [ 102 | { 103 | "command": "registeredCommands.removeEntry", 104 | "when": "view == registeredCommands", 105 | "group": "inline" 106 | }, 107 | { 108 | "command": "registeredCommands.removeEntry", 109 | "when": "view == registeredCommands" 110 | } 111 | ] 112 | }, 113 | "configuration": { 114 | "title": "Shell Completion", 115 | "properties": { 116 | "shellCompletion.h2oPath": { 117 | "type": "string", 118 | "default": "", 119 | "description": "Path to the H2O executable. Enter if using the bundled." 120 | } 121 | } 122 | }, 123 | "views": { 124 | "explorer": [ 125 | { 126 | "id": "registeredCommands", 127 | "name": "Shell Commands", 128 | "visibility": "collapsed" 129 | } 130 | ] 131 | } 132 | }, 133 | "scripts": { 134 | "vscode:prepublish": "npm run compile", 135 | "compile": "tsc -p ./", 136 | "watch": "tsc -watch -p ./", 137 | "pretest": "npm run compile && npm run lint", 138 | "lint": "eslint src --ext ts", 139 | "test": "node ./out/test/runTest.js" 140 | }, 141 | "devDependencies": { 142 | "@types/glob": "^7.2.0", 143 | "@types/mocha": "^10.0.0", 144 | "@types/node": "^18.11.9", 145 | "@types/node-fetch": "^2.5.12", 146 | "@types/pako": "^1.0.2", 147 | "@types/vscode": "^1.63.0", 148 | "@typescript-eslint/eslint-plugin": "^5.7.0", 149 | "@typescript-eslint/parser": "^5.7.0", 150 | "@vscode/test-electron": "^2.1.5", 151 | "eslint": "^8.4.1", 152 | "glob": "^7.2.0", 153 | "mocha": "^10.0.0", 154 | "typescript": "^4.5.4" 155 | }, 156 | "dependencies": { 157 | "node-fetch": "^2.6.6", 158 | "pako": "^2.0.4", 159 | "web-tree-sitter": "^0.20.8" 160 | } 161 | } 162 | -------------------------------------------------------------------------------- /src/analyzer.ts: -------------------------------------------------------------------------------- 1 | import * as Parser from 'web-tree-sitter'; 2 | import { SyntaxNode } from 'web-tree-sitter'; 3 | 4 | // export class Analyzer { 5 | // private fetcher: CachingFetcher; 6 | 7 | // constructor(fetcher) 8 | 9 | // } 10 | 11 | // function () -------------------------------------------------------------------------------- /src/cacheFetcher.ts: -------------------------------------------------------------------------------- 1 | import * as vscode from 'vscode'; 2 | import { Memento } from 'vscode'; 3 | import { spawnSync } from 'child_process'; 4 | import { Command } from './command'; 5 | import fetch from 'node-fetch'; 6 | import { Response } from 'node-fetch'; 7 | import * as pako from 'pako'; 8 | 9 | let neverNotifiedError = true; 10 | 11 | 12 | class HTTPResponseError extends Error { 13 | response: Response; 14 | constructor(res: Response) { 15 | super(`HTTP Error Response: ${res.status} ${res.statusText}`); 16 | this.response = res; 17 | } 18 | } 19 | 20 | 21 | // ----- 22 | // Call H2O executable and get command information from the local environment 23 | export function runH2o(name: string): Command | undefined { 24 | let h2opath = vscode.workspace.getConfiguration('shellCompletion').get('h2oPath') as string; 25 | if (h2opath === '') { 26 | if (process.platform === 'linux') { 27 | h2opath = `${__dirname}/../bin/h2o-x86_64-unknown-linux`; 28 | } else if (process.platform === 'darwin') { 29 | h2opath = `${__dirname}/../bin/h2o-x86_64-apple-darwin`; 30 | } else { 31 | if (neverNotifiedError) { 32 | const msg = "Bundled help scanner (H2O) supports Linux and MacOS. Please set the H2O path."; 33 | vscode.window.showErrorMessage(msg); 34 | } 35 | neverNotifiedError = false; 36 | return; 37 | } 38 | } 39 | 40 | const wrapperPath = `${__dirname}/../bin/wrap-h2o`; 41 | console.log(`[CacheFetcher.runH2o] spawning h2o: ${name}`); 42 | const proc = spawnSync(wrapperPath, [h2opath, name], {encoding: "utf8"}); 43 | if (proc.status !== 0) { 44 | console.log(`[CacheFetcher.runH2o] H2O raises error for ${name}`); 45 | return; 46 | } 47 | console.log(`[CacheFetcher.runH2o] proc.status = ${proc.status}`); 48 | const out = proc.stdout; 49 | if (out) { 50 | const command = JSON.parse(out); 51 | if (command) { 52 | console.log(`[CacheFetcher.runH2o] Got command output: ${command.name}`); 53 | return command; 54 | } else { 55 | console.warn('[CacheFetcher.runH2o] Failed to parse H2O result as JSON:', name); 56 | } 57 | } else { 58 | console.warn('[CacheFetcher.runH2o] Failed to get H2O output:', name); 59 | } 60 | } 61 | 62 | 63 | // ----- 64 | // CachingFetcher manages the local cache using Memento. 65 | // It also pulls command data from the remote repository. 66 | export class CachingFetcher { 67 | static readonly keyPrefix = 'h2oFetcher.cache.'; 68 | static readonly commandListKey = 'h2oFetcher.registered.all'; 69 | 70 | constructor( 71 | private memento: Memento 72 | ) {} 73 | 74 | public async init(): Promise { 75 | const existing = this.getList(); 76 | 77 | if (!existing || !existing.length || existing.length === 0) { 78 | console.log(">>>---------------------------------------"); 79 | console.log(" Clean state"); 80 | console.log("<<<---------------------------------------"); 81 | } else { 82 | console.log(">>>---------------------------------------"); 83 | console.log(" Memento entries already exist"); 84 | console.log(" # of command specs in the local DB:", existing.length); 85 | console.log("<<<---------------------------------------"); 86 | } 87 | } 88 | 89 | // Get Memento key of the command `name` 90 | static getKey(name: string): string { 91 | return CachingFetcher.keyPrefix + name; 92 | } 93 | 94 | // Get Memento data of the command `name` 95 | private getCache(name: string): Command | undefined { 96 | const key = CachingFetcher.getKey(name); 97 | return this.memento.get(key); 98 | } 99 | 100 | // Update Memento record and the name list 101 | // Pass undefined to remove the value. 102 | private async updateCache(name: string, command: Command | undefined, logging: boolean = false): Promise { 103 | if (logging) { 104 | console.log(`[CacheFetcher.update] Updating ${name}...`); 105 | const t0 = new Date(); 106 | const key = CachingFetcher.getKey(name); 107 | await this.memento.update(key, command); 108 | const t1 = new Date(); 109 | const diff = t1.getTime() - t0.getTime(); 110 | console.log(`[CacheFetcher.update] ${name}: Memento update took ${diff} ms.`); 111 | } else { 112 | const key = CachingFetcher.getKey(name); 113 | await this.memento.update(key, command); 114 | } 115 | } 116 | 117 | 118 | // Get command data from cache first, then run H2O if fails. 119 | public async fetch(name: string): Promise { 120 | if (name.length < 2) { 121 | return Promise.reject(`Command name too short: ${name}`); 122 | } 123 | 124 | let cached = this.getCache(name); 125 | if (cached) { 126 | console.log('[CacheFetcher.fetch] Fetching from cache:', name); 127 | return cached as Command; 128 | } 129 | 130 | console.log('[CacheFetcher.fetch] Fetching from H2O:', name); 131 | try { 132 | const command = runH2o(name); 133 | if (!command) { 134 | console.warn(`[CacheFetcher.fetch] Failed to fetch command ${name} from H2O`); 135 | return Promise.reject(`Failed to fetch command ${name} from H2O`); 136 | } 137 | try { 138 | this.updateCache(name, command, true); 139 | } catch (e) { 140 | console.log("Failed to update:", e); 141 | } 142 | return command; 143 | 144 | } catch (e) { 145 | console.log("[CacheFetcher.fetch] Error: ", e); 146 | return Promise.reject(`[CacheFetcher.fetch] Failed in CacheFetcher.update() with name = ${name}`); 147 | } 148 | } 149 | 150 | 151 | // Download the package bundle `kind` and load them to cache 152 | public async fetchAllCurated(kind = 'general', isForcing = false): Promise { 153 | console.log("[CacheFetcher.fetchAllCurated] Started running..."); 154 | const url = `https://github.com/yamaton/h2o-curated-data/raw/main/${kind}.json.gz`; 155 | const checkStatus = (res: Response) => { 156 | if (res.ok) { 157 | return res; 158 | } else { 159 | throw new HTTPResponseError(res); 160 | } 161 | }; 162 | 163 | let response: Response; 164 | try { 165 | response = await fetch(url); 166 | checkStatus(response); 167 | } catch (error) { 168 | try { 169 | const err = error as HTTPResponseError; 170 | const errorBody = await err.response.text(); 171 | console.error(`Error body: ${errorBody}`); 172 | return Promise.reject("Failed to fetch HTTP response."); 173 | } catch (e) { 174 | console.error('Error ... even failed to fetch error body:', e); 175 | return Promise.reject("Failed to fetch over HTTP"); 176 | } 177 | } 178 | console.log("[CacheFetcher.fetchAllCurated] received HTTP response"); 179 | 180 | let commands: Command[] = []; 181 | try { 182 | const s = await response.buffer(); 183 | const decoded = pako.inflate(s, { to: 'string' }); 184 | commands = JSON.parse(decoded) as Command[]; 185 | } catch (err) { 186 | console.error("[fetchAllCurated] Error: ", err); 187 | return Promise.reject("Failed to inflate and parse the content as JSON."); 188 | } 189 | console.log("[CacheFetcher.fetchAllCurated] Done inflating and parsing. Command #:", commands.length); 190 | 191 | for (const cmd of commands) { 192 | const key = CachingFetcher.getKey(cmd.name); 193 | if (isForcing || this.getCache(cmd.name) === undefined) { 194 | this.updateCache(cmd.name, cmd, false); 195 | } 196 | } 197 | } 198 | 199 | 200 | // Download the command `name` from the remote repository 201 | public async downloadCommandToCache(name: string, kind = 'experimental'): Promise { 202 | console.log(`[CacheFetcher.downloadCommand] Started getting ${name} in ${kind}...`); 203 | const url = `https://raw.githubusercontent.com/yamaton/h2o-curated-data/main/${kind}/json/${name}.json`; 204 | const checkStatus = (res: Response) => { 205 | if (res.ok) { 206 | return res; 207 | } else { 208 | throw new HTTPResponseError(res); 209 | } 210 | }; 211 | 212 | let response: Response; 213 | try { 214 | response = await fetch(url); 215 | checkStatus(response); 216 | } catch (error) { 217 | try { 218 | const err = error as HTTPResponseError; 219 | const errorBody = await err.response.text(); 220 | console.error(`Error body: ${errorBody}`); 221 | return Promise.reject("Failed to fetch HTTP response."); 222 | } catch (e) { 223 | console.error('Error ... even failed to fetch error body:', e); 224 | return Promise.reject("Failed to fetch over HTTP"); 225 | } 226 | } 227 | console.log("[CacheFetcher.downloadCommand] received HTTP response"); 228 | 229 | let cmd: Command; 230 | try { 231 | const content = await response.text(); 232 | cmd = JSON.parse(content) as Command; 233 | } catch (err) { 234 | const msg = `[CacheFetcher.downloadCommand] Error: ${err}`; 235 | console.error(msg); 236 | return Promise.reject(msg); 237 | } 238 | 239 | console.log(`[CacheFetcher.downloadCommand] Loading: ${cmd.name}`); 240 | this.updateCache(cmd.name, cmd, true); 241 | } 242 | 243 | 244 | // Get a list of the command bundle `kind`. 245 | // This is used for removal of bundled commands. 246 | public async fetchList(kind = 'bio'): Promise { 247 | console.log("[CacheFetcher.fetchList] Started running..."); 248 | const url = `https://raw.githubusercontent.com/yamaton/h2o-curated-data/main/${kind}.txt`; 249 | const checkStatus = (res: Response) => { 250 | if (res.ok) { 251 | return res; 252 | } else { 253 | throw new HTTPResponseError(res); 254 | } 255 | }; 256 | 257 | let response: Response; 258 | try { 259 | response = await fetch(url); 260 | checkStatus(response); 261 | } catch (error) { 262 | try { 263 | const err = error as HTTPResponseError; 264 | const errorBody = await err.response.text(); 265 | console.error(`Error body: ${errorBody}`); 266 | return Promise.reject("Failed to fetch HTTP response."); 267 | } catch (e) { 268 | console.error('Error ... even failed to fetch error body:', e); 269 | return Promise.reject("Failed to fetch over HTTP"); 270 | } 271 | } 272 | console.log("[CacheFetcher.fetchList] received HTTP response"); 273 | 274 | let names: string[] = []; 275 | try { 276 | const content = await response.text(); 277 | names = content.split(/\r?\n/).map((str) => str.trim()).filter(s => !!s && s.length > 0); 278 | } catch (err) { 279 | const msg = `[CacheFetcher.fetchList] Error: ${err}`; 280 | console.error(msg); 281 | return Promise.reject(msg); 282 | } 283 | names.forEach((name) => console.log(" Received ", name)); 284 | return names; 285 | } 286 | 287 | // Unset cache data of command `name` by assigning undefined 288 | public async unset(name: string): Promise { 289 | await this.updateCache(name, undefined); 290 | console.log(`[CacheFetcher.unset] Unset ${name}`); 291 | } 292 | 293 | // Load a list of registered commands from Memento 294 | public getList(): string[] { 295 | const keys = this.memento.keys(); 296 | const prefix = CachingFetcher.keyPrefix; 297 | const cmdKeys = 298 | keys.filter(x => x.startsWith(prefix)) 299 | .map(x => x.substring(prefix.length)); 300 | return cmdKeys; 301 | } 302 | 303 | } 304 | -------------------------------------------------------------------------------- /src/command.ts: -------------------------------------------------------------------------------- 1 | export interface Option { 2 | names: string[], 3 | argument: string, 4 | description: string, 5 | } 6 | 7 | export interface Command { 8 | name: string, 9 | description: string, 10 | options: Option[], 11 | subcommands?: Command[], 12 | inheritedOptions?: Option[], 13 | aliases?: string[], 14 | tldr?: string, 15 | usage?: string, 16 | } 17 | 18 | -------------------------------------------------------------------------------- /src/commandExplorer.ts: -------------------------------------------------------------------------------- 1 | import * as vscode from 'vscode'; 2 | import { CachingFetcher } from './cacheFetcher'; 3 | import * as path from 'path'; 4 | 5 | 6 | export class CommandListProvider implements vscode.TreeDataProvider { 7 | constructor(private fetcher: CachingFetcher) {} 8 | 9 | private _onDidChangeTreeData: vscode.EventEmitter = new vscode.EventEmitter(); 10 | readonly onDidChangeTreeData: vscode.Event = this._onDidChangeTreeData.event; 11 | 12 | refresh(): void { 13 | this._onDidChangeTreeData.fire(); 14 | } 15 | 16 | getTreeItem(element: CommandName): vscode.TreeItem { 17 | return element; 18 | } 19 | 20 | getChildren(element?: CommandName): CommandName[] { 21 | if (!element) { 22 | return this.getCommandNames(); 23 | } 24 | console.warn("CommandListProvider: Something is wrong."); 25 | return []; 26 | } 27 | 28 | /** 29 | * Given the path to package.json, read all its dependencies and devDependencies. 30 | */ 31 | private getCommandNames(): CommandName[] { 32 | const xs = this.fetcher.getList().sort(); 33 | 34 | const toCommandName = (name: string): CommandName => { 35 | return new CommandName(name, vscode.TreeItemCollapsibleState.None); 36 | }; 37 | console.info(`getCommandNames(): xs = ${xs}`); 38 | return xs.map(toCommandName); 39 | } 40 | } 41 | 42 | 43 | class CommandName extends vscode.TreeItem { 44 | constructor( 45 | public readonly label: string, 46 | public readonly collapsibleState: vscode.TreeItemCollapsibleState 47 | ) { 48 | super(label, collapsibleState); 49 | this.tooltip = `${this.label}`; 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /src/extension.ts: -------------------------------------------------------------------------------- 1 | import * as vscode from 'vscode'; 2 | import * as Parser from 'web-tree-sitter'; 3 | import { SyntaxNode } from 'web-tree-sitter'; 4 | import { CachingFetcher } from './cacheFetcher'; 5 | import { Option, Command } from './command'; 6 | import { CommandListProvider } from './commandExplorer'; 7 | import { formatTldr, isPrefixOf, getLabelString, formatUsage, formatDescription } from './utils'; 8 | 9 | 10 | async function initializeParser(): Promise { 11 | await Parser.init(); 12 | const parser = new Parser; 13 | const path = `${__dirname}/../tree-sitter-bash.wasm`; 14 | const lang = await Parser.Language.load(path); 15 | parser.setLanguage(lang); 16 | return parser; 17 | } 18 | 19 | export async function activate(context: vscode.ExtensionContext) { 20 | const parser = await initializeParser(); 21 | const trees: { [uri: string]: Parser.Tree } = {}; 22 | const fetcher = new CachingFetcher(context.globalState); 23 | await fetcher.init(); 24 | try { 25 | await fetcher.fetchAllCurated("general"); 26 | } catch { 27 | console.warn("Failed in fetch.fetchAllCurated()."); 28 | } 29 | 30 | 31 | const compprovider = vscode.languages.registerCompletionItemProvider( 32 | 'shellscript', 33 | { 34 | async provideCompletionItems(document, position, token, context) { 35 | if (!parser) { 36 | console.error("[Completion] Parser is unavailable!"); 37 | return Promise.reject("Parser unavailable!"); 38 | } 39 | if (!trees[document.uri.toString()]) { 40 | console.log("[Completion] Creating tree"); 41 | trees[document.uri.toString()] = parser.parse(document.getText()); 42 | } 43 | const tree = trees[document.uri.toString()]; 44 | const commandList = fetcher.getList(); 45 | let compCommands: vscode.CompletionItem[] = []; 46 | if (!!commandList) { 47 | compCommands = commandList.map((s) => new vscode.CompletionItem(s)); 48 | } 49 | 50 | // this is an ugly hack to get current Node 51 | const p = walkbackIfNeeded(document, tree.rootNode, position); 52 | const isCursorTouchingWord = (p === position); 53 | console.log(`[Completion] isCursorTouchingWord: ${isCursorTouchingWord}`); 54 | 55 | try { 56 | const cmdSeq = await getContextCmdSeq(tree.rootNode, p, fetcher); 57 | if (!!cmdSeq && cmdSeq.length) { 58 | const deepestCmd = cmdSeq[cmdSeq.length - 1]; 59 | const compSubcommands = getCompletionsSubcommands(deepestCmd); 60 | let compOptions = getCompletionsOptions(document, tree.rootNode, p, cmdSeq); 61 | let compItems = [ 62 | ...compSubcommands, 63 | ...compOptions, 64 | ]; 65 | 66 | if (isCursorTouchingWord) { 67 | const currentNode = getCurrentNode(tree.rootNode, position); 68 | const currentWord = currentNode.text; 69 | compItems = compItems.filter(compItem => isPrefixOf(currentWord, getLabelString(compItem.label))); 70 | compItems.forEach(compItem => { 71 | compItem.range = range(currentNode); 72 | }); 73 | console.info(`[Completion] currentWord: ${currentWord}`); 74 | } 75 | return compItems; 76 | } else { 77 | throw new Error("unknown command"); 78 | } 79 | } catch (e) { 80 | const currentNode = getCurrentNode(tree.rootNode, position); 81 | const currentWord = currentNode.text; 82 | console.info(`[Completion] currentWord = ${currentWord}`); 83 | if (!!compCommands && p === position && currentWord.length >= 2) { 84 | console.info("[Completion] Only command completion is available (2)"); 85 | let compItems = compCommands.filter(cmd => isPrefixOf(currentWord, getLabelString(cmd.label))); 86 | compItems.forEach(compItem => { 87 | compItem.range = range(currentNode); 88 | }); 89 | return compItems; 90 | } 91 | console.warn("[Completion] No completion item is available (1)", e); 92 | return Promise.reject("Error: No completion item is available"); 93 | } 94 | } 95 | }, 96 | ' ', // triggerCharacter 97 | ); 98 | 99 | const hoverprovider = vscode.languages.registerHoverProvider('shellscript', { 100 | async provideHover(document, position, token) { 101 | 102 | if (!parser) { 103 | console.error("[Hover] Parser is unavailable!"); 104 | return Promise.reject("Parser is unavailable!"); 105 | } 106 | 107 | if (!trees[document.uri.toString()]) { 108 | console.log("[Hover] Creating tree"); 109 | trees[document.uri.toString()] = parser.parse(document.getText()); 110 | } 111 | const tree = trees[document.uri.toString()]; 112 | 113 | const currentWord = getCurrentNode(tree.rootNode, position).text; 114 | try { 115 | const cmdSeq = await getContextCmdSeq(tree.rootNode, position, fetcher); 116 | if (!!cmdSeq && cmdSeq.length) { 117 | const name = cmdSeq[0].name; 118 | if (currentWord === name) { 119 | // Display root-level command 120 | const clearCacheCommandUri = vscode.Uri.parse(`command:h2o.clearCache?${encodeURIComponent(JSON.stringify(name))}`); 121 | const thisCmd = cmdSeq.find((cmd) => cmd.name === currentWord)!; 122 | const tldrText = formatTldr(thisCmd.tldr); 123 | const usageText = formatUsage(thisCmd.usage); 124 | const descText = (thisCmd.description !== thisCmd.name && !tldrText) ? formatDescription(thisCmd.description) : ""; 125 | const msg = new vscode.MarkdownString(`\`${name}\`${descText}${usageText}${tldrText}\n\n[Reset](${clearCacheCommandUri})`); 126 | msg.isTrusted = true; 127 | return new vscode.Hover(msg); 128 | } else if (cmdSeq.length > 1 && cmdSeq.some((cmd) => cmd.name === currentWord)) { 129 | // Display a subcommand 130 | const thatCmd = cmdSeq.find((cmd) => cmd.name === currentWord)!; 131 | const nameSeq: string[] = []; 132 | for (const cmd of cmdSeq) { 133 | if (cmd.name !== currentWord) { 134 | nameSeq.push(cmd.name); 135 | } else { 136 | break; 137 | } 138 | } 139 | const cmdPrefixName = nameSeq.join(" "); 140 | const usageText = formatUsage(thatCmd.usage); 141 | const msg = `${cmdPrefixName} **${thatCmd.name}**\n\n${thatCmd.description}${usageText}`; 142 | return new vscode.Hover(new vscode.MarkdownString(msg)); 143 | } else if (cmdSeq.length) { 144 | const opts = getMatchingOption(currentWord, name, cmdSeq); 145 | const msg = optsToMessage(opts); 146 | return new vscode.Hover(new vscode.MarkdownString(msg)); 147 | } else { 148 | return Promise.reject(`No hover is available for ${currentWord}`); 149 | } 150 | } 151 | } catch (e) { 152 | console.log("[Hover] Error: ", e); 153 | return Promise.reject("No hover is available"); 154 | } 155 | } 156 | }); 157 | 158 | function updateTree(p: Parser, edit: vscode.TextDocumentChangeEvent) { 159 | if (edit.document.isClosed || edit.contentChanges.length === 0) { return; } 160 | 161 | const old = trees[edit.document.uri.toString()]; 162 | if (!!old) { 163 | for (const e of edit.contentChanges) { 164 | const startIndex = e.rangeOffset; 165 | const oldEndIndex = e.rangeOffset + e.rangeLength; 166 | const newEndIndex = e.rangeOffset + e.text.length; 167 | const indices = [startIndex, oldEndIndex, newEndIndex]; 168 | const [startPosition, oldEndPosition, newEndPosition] = indices.map(i => asPoint(edit.document.positionAt(i))); 169 | const delta = { startIndex, oldEndIndex, newEndIndex, startPosition, oldEndPosition, newEndPosition }; 170 | old.edit(delta); 171 | } 172 | } 173 | const t = p.parse(edit.document.getText(), old); 174 | trees[edit.document.uri.toString()] = t; 175 | } 176 | 177 | function edit(edit: vscode.TextDocumentChangeEvent) { 178 | updateTree(parser, edit); 179 | } 180 | 181 | function close(document: vscode.TextDocument) { 182 | console.log("[Close] removing a tree"); 183 | const t = trees[document.uri.toString()]; 184 | if (t) { 185 | t.delete(); 186 | delete trees[document.uri.toString()]; 187 | } 188 | } 189 | 190 | 191 | // h2o.loadCommand: Download the command `name` 192 | const loadCommand = vscode.commands.registerCommand('h2o.loadCommand', async (name: string) => { 193 | let cmd = name; 194 | if (!name) { 195 | cmd = (await vscode.window.showInputBox({ placeHolder: 'which command?' }))!; 196 | } 197 | 198 | if (!cmd || !cmd.trim()) { 199 | console.info("[h2o.loadCommand] Cancelled operation."); 200 | return; 201 | } 202 | 203 | try { 204 | console.log(`[Command] Downloading ${cmd} data...`); 205 | await fetcher.downloadCommandToCache(cmd); 206 | const msg = `[Shell Completion] Added ${cmd}.`; 207 | vscode.window.showInformationMessage(msg); 208 | } catch (e) { 209 | console.error("Error: ", e); 210 | return Promise.reject(`[h2o.loadCommand] Failed to load ${cmd}`); 211 | } 212 | }); 213 | 214 | 215 | // h2o.clearCache: Clear cache of the command `name` 216 | const clearCacheCommand = vscode.commands.registerCommand('h2o.clearCache', async (name: string) => { 217 | let cmd = name; 218 | if (!name) { 219 | cmd = (await vscode.window.showInputBox({ placeHolder: 'which command?' }))!; 220 | } 221 | 222 | if (!cmd || !cmd.trim()) { 223 | console.info("[h2o.clearCacheCommand] Cancelled operation."); 224 | return; 225 | } 226 | 227 | try { 228 | console.log(`[h2o.clearCacheCommand] Clearing cache for ${cmd}`); 229 | await fetcher.unset(cmd); 230 | const msg = `[Shell Completion] Cleared ${cmd}`; 231 | vscode.window.showInformationMessage(msg); 232 | } catch (e) { 233 | console.error("Error: ", e); 234 | return Promise.reject("[h2o.clearCacheCommand] Failed"); 235 | } 236 | 237 | }); 238 | 239 | // h2o.loadCommon: Download the package bundle "common" 240 | const invokeDownloadingCommon = vscode.commands.registerCommand('h2o.loadCommon', async () => { 241 | try { 242 | console.log('[h2o.loadCommon] Load common CLI data'); 243 | const msg1 = `[Shell Completion] Loading common CLI data...`; 244 | vscode.window.showInformationMessage(msg1); 245 | 246 | await fetcher.fetchAllCurated('general', true); 247 | } catch (e) { 248 | console.error("[h2o.loadCommon] Error: ", e); 249 | const msg = `[Shell Completion] Error: Failed to load common CLI specs`; 250 | vscode.window.showInformationMessage(msg); 251 | return Promise.reject("[h2o.loadCommon] Error: "); 252 | } 253 | 254 | const msg = `[Shell Completion] Succssfully loaded common CLI specs`; 255 | vscode.window.showInformationMessage(msg); 256 | }); 257 | 258 | 259 | // h2o.loadBio: Download the command bundle "bio" 260 | const invokeDownloadingBio = vscode.commands.registerCommand('h2o.loadBio', async () => { 261 | try { 262 | console.log('[h2o.loadBio] Load Bioinformatics CLI data'); 263 | const msg1 = `[Shell Completion] Loading bioinformatics CLI specs...`; 264 | vscode.window.showInformationMessage(msg1); 265 | 266 | await fetcher.fetchAllCurated('bio', true); 267 | } catch (e) { 268 | console.error("[h2o.loadBio] Error: ", e); 269 | return Promise.reject("[h2o.loadBio] Failed to load the Bio package"); 270 | } 271 | 272 | const msg = `[Shell Completion] Succssfully loaded bioinformatics CLI specs!`; 273 | vscode.window.showInformationMessage(msg); 274 | }); 275 | 276 | 277 | // h2o.removeBio: Remove the command bundle "bio" 278 | const removeBio = vscode.commands.registerCommand('h2o.removeBio', async () => { 279 | try { 280 | console.log('[h2o.removeBio] Remove Bioinformatics CLI data'); 281 | const msg1 = `[Shell Completion] Removing bioinformatics CLI specs...`; 282 | vscode.window.showInformationMessage(msg1); 283 | 284 | const names = await fetcher.fetchList('bio'); 285 | names.forEach(async (name) => await fetcher.unset(name)); 286 | } catch (e) { 287 | console.error("[h2o.removeBio] Error: ", e); 288 | return Promise.reject("[h2o.removeBio] Fetch Error: "); 289 | } 290 | 291 | const msg = `[Shell Completion] Succssfully removed bioinformatics CLI specs!`; 292 | vscode.window.showInformationMessage(msg); 293 | }); 294 | 295 | 296 | // Command Explorer 297 | const commandListProvider = new CommandListProvider(fetcher); 298 | vscode.window.registerTreeDataProvider('registeredCommands', commandListProvider); 299 | vscode.commands.registerCommand('registeredCommands.refreshEntry', () => 300 | commandListProvider.refresh() 301 | ); 302 | 303 | vscode.commands.registerCommand('registeredCommands.removeEntry', async (item: vscode.TreeItem) => { 304 | if (!!item && !!item.label) { 305 | const name = item.label as string; 306 | console.log(`[registeredCommands.removeEntry] Remove ${name}`); 307 | await fetcher.unset(name); 308 | commandListProvider.refresh(); 309 | } 310 | }); 311 | 312 | 313 | context.subscriptions.push(clearCacheCommand); 314 | context.subscriptions.push(loadCommand); 315 | context.subscriptions.push(invokeDownloadingCommon); 316 | context.subscriptions.push(invokeDownloadingBio); 317 | context.subscriptions.push(removeBio); 318 | context.subscriptions.push(vscode.workspace.onDidChangeTextDocument(edit)); 319 | context.subscriptions.push(vscode.workspace.onDidCloseTextDocument(close)); 320 | context.subscriptions.push(compprovider); 321 | context.subscriptions.push(hoverprovider); 322 | 323 | } 324 | 325 | 326 | // Convert: vscode.Position -> Parser.Point 327 | function asPoint(p: vscode.Position): Parser.Point { 328 | return { row: p.line, column: p.character }; 329 | } 330 | 331 | // Convert: option -> UI text (string) 332 | function optsToMessage(opts: Option[]): string { 333 | if (opts.length === 1) { 334 | const opt = opts[0]; 335 | const namestr = opt.names.map((s) => `\`${s}\``).join(', '); 336 | const argstr = (!!opt.argument) ? `\`${opt.argument}\`` : ""; 337 | const msg = `${namestr} ${argstr}\n\n ${opt.description}`; 338 | return msg; 339 | 340 | } else { 341 | // deal with stacked option 342 | const namestrs = opts.map(opt => opt.names.map((s) => `\`${s}\``).join(', ')); 343 | const messages = opts.map((opt, i) => `${namestrs[i]}\n\n ${opt.description}`); 344 | const joined = messages.join("\n\n"); 345 | return joined; 346 | } 347 | } 348 | 349 | 350 | // --------------- Helper ---------------------- 351 | 352 | function range(n: SyntaxNode): vscode.Range { 353 | return new vscode.Range( 354 | n.startPosition.row, 355 | n.startPosition.column, 356 | n.endPosition.row, 357 | n.endPosition.column, 358 | ); 359 | } 360 | 361 | 362 | // --------------- For Hovers and Completions ---------------------- 363 | 364 | // Find the deepest node that contains the position in its range. 365 | function getCurrentNode(n: SyntaxNode, position: vscode.Position): SyntaxNode { 366 | if (!(range(n).contains(position))) { 367 | console.error("Out of range!"); 368 | } 369 | for (const child of n.children) { 370 | const r = range(child); 371 | if (r.contains(position)) { 372 | return getCurrentNode(child, position); 373 | } 374 | } 375 | return n; 376 | } 377 | 378 | 379 | // Moves the position left by one character IF position is contained only in the root-node range. 380 | // This is just a workround as you cannot reach command node if you start from 381 | // the position, say, after 'echo ' 382 | // [FIXME] Do not rely on such an ugly hack 383 | function walkbackIfNeeded(document: vscode.TextDocument, root: SyntaxNode, position: vscode.Position): vscode.Position { 384 | const thisNode = getCurrentNode(root, position); 385 | console.debug("[walkbackIfNeeded] thisNode.type: ", thisNode.type); 386 | if (thisNode.type === ';') { 387 | console.info("[walkbackIfNeeded] stop at semicolon."); 388 | return position; 389 | } 390 | 391 | if (position.character > 0 && thisNode.type !== 'word') { 392 | console.info("[walkbackIfNeeded] stepping back!"); 393 | return walkbackIfNeeded(document, root, position.translate(0, -1)); 394 | } else if (thisNode.type !== 'word' && position.character === 0 && position.line > 0) { 395 | const prevLineIndex = position.line - 1; 396 | const prevLine = document.lineAt(prevLineIndex); 397 | if (prevLine.text.trimEnd().endsWith('\\')) { 398 | const charIndex = prevLine.text.trimEnd().length - 1; 399 | return walkbackIfNeeded(document, root, new vscode.Position(prevLineIndex, charIndex)); 400 | } 401 | } 402 | return position; 403 | } 404 | 405 | 406 | // Returns current word as an option if the tree-sitter says so 407 | function getMatchingOption(currentWord: string, name: string, cmdSeq: Command[]): Option[] { 408 | const thisName = currentWord.split('=', 2)[0]; 409 | if (thisName.startsWith('-')) { 410 | const options = getOptions(cmdSeq); 411 | const theOption = options.find((x) => x.names.includes(thisName)); 412 | if (theOption) { 413 | return [theOption]; 414 | } else if (isOldStyle(thisName)) { 415 | // deal with a stacked options like `-xvf` 416 | // or, a short option immediately followed by an argument, i.e. '-oArgument' 417 | const shortOptionNames = unstackOption(thisName); 418 | const shortOptions = shortOptionNames.map(short => options.find(opt => opt.names.includes(short))!).filter(opt => opt); 419 | if (shortOptionNames.length > 1 && shortOptionNames.length === shortOptions.length) { 420 | return shortOptions; // i.e. -xvf 421 | } else if (shortOptions.length > 0) { 422 | return [shortOptions[0]]; // i.e. -oArgument 423 | } 424 | } 425 | } 426 | return []; 427 | } 428 | 429 | function isOldStyle(name: string): boolean { 430 | return name.startsWith('-') && !name.startsWith('--') && name.length > 2; 431 | } 432 | 433 | function unstackOption(name: string): string[] { 434 | const xs = name.substring(1).split('').map(c => c.padStart(2, '-')); 435 | if (!xs.length) { 436 | return []; 437 | } 438 | const ys = new Set(xs); 439 | if (xs.length !== ys.size) { 440 | // if characters are NOT unique like -baba 441 | // then it returns ['-b'] assuming 'aba' is the argument 442 | return [xs[0]]; 443 | } 444 | return xs; 445 | } 446 | 447 | // Get command node inferred from the current position 448 | function _getContextCommandNode(root: SyntaxNode, position: vscode.Position): SyntaxNode | undefined { 449 | let currentNode = getCurrentNode(root, position); 450 | if (currentNode.parent?.type === 'command_name') { 451 | currentNode = currentNode.parent; 452 | } 453 | if (currentNode.parent?.type === 'command') { 454 | return currentNode.parent; 455 | } 456 | } 457 | 458 | // Get command name covering the position if exists 459 | function getContextCommandName(root: SyntaxNode, position: vscode.Position): string | undefined { 460 | // if you are at a command, a named node, the currentNode becomes one-layer deeper than other nameless nodes. 461 | const commandNode = _getContextCommandNode(root, position); 462 | let name = commandNode?.firstNamedChild?.text!; 463 | if (name === 'sudo' || name === 'nohup') { 464 | name = commandNode?.firstNamedChild?.nextSibling?.text!; 465 | } 466 | return name; 467 | } 468 | 469 | // Get subcommand names NOT starting with `-` 470 | // [FIXME] this catches option's argument; use database instead 471 | function _getSubcommandCandidates(root: SyntaxNode, position: vscode.Position): string[] { 472 | const candidates: string[] = []; 473 | let commandNode = _getContextCommandNode(root, position)!; 474 | if (commandNode) { 475 | let n = commandNode?.firstNamedChild; 476 | while (n?.nextSibling) { 477 | n = n?.nextSibling; 478 | if (!n.text.startsWith('-')) { 479 | candidates.push(n.text); 480 | } 481 | } 482 | } 483 | return candidates; 484 | } 485 | 486 | 487 | // Get command and subcommand inferred from the current position 488 | async function getContextCmdSeq(root: SyntaxNode, position: vscode.Position, fetcher: CachingFetcher): Promise { 489 | let name = getContextCommandName(root, position); 490 | if (!name) { 491 | return Promise.reject("[getContextCmdSeq] Command name not found."); 492 | } 493 | 494 | try { 495 | let command = await fetcher.fetch(name); 496 | const seq: Command[] = [command]; 497 | if (!!command) { 498 | const words = _getSubcommandCandidates(root, position); 499 | let found = true; 500 | while (found && !!command.subcommands && command.subcommands.length) { 501 | found = false; 502 | const subcommands = getSubcommandsWithAliases(command); 503 | for (const word of words) { 504 | for (const subcmd of subcommands) { 505 | if (subcmd.name === word) { 506 | command = subcmd; 507 | seq.push(command); 508 | found = true; 509 | } 510 | } 511 | } 512 | } 513 | } 514 | return seq; 515 | } catch (e) { 516 | console.error("[getContextCmdSeq] Error: ", e); 517 | return Promise.reject("[getContextCmdSeq] unknown command!"); 518 | } 519 | } 520 | 521 | 522 | // Get command arguments as string[] 523 | function getContextCmdArgs(document: vscode.TextDocument, root: SyntaxNode, position: vscode.Position): string[] { 524 | const p = walkbackIfNeeded(document, root, position); 525 | let node = _getContextCommandNode(root, p)?.firstNamedChild; 526 | if (node?.text === 'sudo' || node?.text === 'nohup') { 527 | node = node.nextSibling; 528 | } 529 | const res: string[] = []; 530 | while (node?.nextSibling) { 531 | node = node.nextSibling; 532 | let text = node.text; 533 | // --option=arg 534 | if (text.startsWith('--') && text.includes('=')) { 535 | text = text.split('=', 2)[0]; 536 | } 537 | res.push(text); 538 | } 539 | return res; 540 | } 541 | 542 | 543 | // Get subcommand completions 544 | function getCompletionsSubcommands(deepestCmd: Command): vscode.CompletionItem[] { 545 | const subcommands = getSubcommandsWithAliases(deepestCmd); 546 | if (subcommands && subcommands.length) { 547 | const compitems = subcommands.map((sub, idx) => { 548 | const item = createCompletionItem(sub.name, sub.description); 549 | item.sortText = `33-${idx.toString().padStart(4)}`; 550 | return item; 551 | }); 552 | return compitems; 553 | } 554 | return []; 555 | } 556 | 557 | 558 | // Get option completion 559 | function getCompletionsOptions(document: vscode.TextDocument, root: SyntaxNode, position: vscode.Position, cmdSeq: Command[]): vscode.CompletionItem[] { 560 | const args = getContextCmdArgs(document, root, position); 561 | const compitems: vscode.CompletionItem[] = []; 562 | const options = getOptions(cmdSeq); 563 | options.forEach((opt, idx) => { 564 | // suppress already-used options 565 | if (opt.names.every(name => !args.includes(name))) { 566 | opt.names.forEach(name => { 567 | const item = createCompletionItem(name, opt.description); 568 | item.sortText = `55-${idx.toString().padStart(4)}`; 569 | if (opt.argument) { 570 | const snippet = `${name} \$\{1:${opt.argument}\}`; 571 | item.insertText = new vscode.SnippetString(snippet); 572 | } 573 | compitems.push(item); 574 | }); 575 | } 576 | }); 577 | return compitems; 578 | } 579 | 580 | 581 | function createCompletionItem(label: string, desc: string): vscode.CompletionItem { 582 | return new vscode.CompletionItem({ label: label, description: desc }); 583 | } 584 | 585 | 586 | // Get options including inherited ones 587 | function getOptions(cmdSeq: Command[]): Option[] { 588 | const inheritedOptionsArray = cmdSeq.map(x => (!!x.inheritedOptions) ? x.inheritedOptions : []); 589 | const deepestCmd = cmdSeq[cmdSeq.length - 1]; 590 | const options = (!!deepestCmd && !!deepestCmd.options) ? deepestCmd.options.concat(...inheritedOptionsArray) : []; 591 | return options; 592 | } 593 | 594 | 595 | // Get subcommands including aliases of a subcommands 596 | function getSubcommandsWithAliases(cmd: Command): Command[] { 597 | const subcommands = cmd.subcommands; 598 | if (!subcommands) { 599 | return []; 600 | } 601 | 602 | const res: Command[] = []; 603 | for (let subcmd of subcommands) { 604 | res.push(subcmd); 605 | if (!!subcmd.aliases) { 606 | for (const alias of subcmd.aliases) { 607 | const aliasCmd = { ...subcmd }; 608 | aliasCmd.name = alias; 609 | aliasCmd.description = `(Alias of ${subcmd.name}) `.concat(aliasCmd.description); 610 | res.push(aliasCmd); 611 | } 612 | } 613 | } 614 | return res; 615 | } 616 | 617 | export function deactivate() { } 618 | -------------------------------------------------------------------------------- /src/test/runTest.ts: -------------------------------------------------------------------------------- 1 | import * as path from 'path'; 2 | 3 | import { runTests } from '@vscode/test-electron'; 4 | 5 | async function main() { 6 | try { 7 | // The folder containing the Extension Manifest package.json 8 | // Passed to `--extensionDevelopmentPath` 9 | const extensionDevelopmentPath = path.resolve(__dirname, '../../'); 10 | 11 | // The path to test runner 12 | // Passed to --extensionTestsPath 13 | const extensionTestsPath = path.resolve(__dirname, './suite/index'); 14 | 15 | // Download VS Code, unzip it and run the integration test 16 | await runTests({ extensionDevelopmentPath, extensionTestsPath }); 17 | } catch (err) { 18 | console.error('Failed to run tests'); 19 | process.exit(1); 20 | } 21 | } 22 | 23 | main(); 24 | -------------------------------------------------------------------------------- /src/test/suite/extension.test.ts: -------------------------------------------------------------------------------- 1 | import * as assert from 'assert'; 2 | 3 | // You can import and use all API from the 'vscode' module 4 | // as well as import your extension to test it 5 | import * as vscode from 'vscode'; 6 | // import * as myExtension from '../../extension'; 7 | 8 | suite('Extension Test Suite', () => { 9 | vscode.window.showInformationMessage('Start all tests.'); 10 | 11 | test('Sample test', () => { 12 | assert.strictEqual(-1, [1, 2, 3].indexOf(5)); 13 | assert.strictEqual(-1, [1, 2, 3].indexOf(0)); 14 | }); 15 | }); 16 | -------------------------------------------------------------------------------- /src/test/suite/index.ts: -------------------------------------------------------------------------------- 1 | import * as path from 'path'; 2 | import * as Mocha from 'mocha'; 3 | import * as glob from 'glob'; 4 | 5 | export function run(): Promise { 6 | // Create the mocha test 7 | const mocha = new Mocha({ 8 | ui: 'tdd', 9 | color: true 10 | }); 11 | 12 | const testsRoot = path.resolve(__dirname, '..'); 13 | 14 | return new Promise((c, e) => { 15 | glob('**/**.test.js', { cwd: testsRoot }, (err, files) => { 16 | if (err) { 17 | return e(err); 18 | } 19 | 20 | // Add files to the test suite 21 | files.forEach(f => mocha.addFile(path.resolve(testsRoot, f))); 22 | 23 | try { 24 | // Run the mocha test 25 | mocha.run(failures => { 26 | if (failures > 0) { 27 | e(new Error(`${failures} tests failed.`)); 28 | } else { 29 | c(); 30 | } 31 | }); 32 | } catch (err) { 33 | console.error(err); 34 | e(err); 35 | } 36 | }); 37 | }); 38 | } 39 | -------------------------------------------------------------------------------- /src/utils.ts: -------------------------------------------------------------------------------- 1 | import * as vscode from 'vscode'; 2 | 3 | // Format tldr pages by cleaning tldr-specific notations {{path/to/file}} 4 | // as well as removing the title starting with '#'. 5 | export function formatTldr(text: string | undefined): string { 6 | if (!text || !text.length) { 7 | return ""; 8 | } 9 | const s = text.replace(/{{(.*?)}}/g, "$1"); 10 | const formatted = s 11 | .split("\n") 12 | .filter((line: string) => !line.trimStart().startsWith("#")) 13 | .map(line => line.replace(/^`(.*)`$/gi, ' ```\n $1\n ```\n')) 14 | .map(line => line.replace(/^\> /gi, '\n')) 15 | .join("\n") 16 | .trimStart(); 17 | return `\n\n${formatted}`; 18 | } 19 | 20 | // Format usage 21 | export function formatUsage(text: string | undefined): string { 22 | if (!text || !text.trim().length) { 23 | return ""; 24 | } 25 | const trimmed = text.trim(); 26 | const xs = trimmed.split("\n"); 27 | const formatted = `Usage:\n\n${xs.map(x => ' ' + x).join("\n")}\n\n`; 28 | return `\n\n${formatted}`; 29 | } 30 | 31 | // Format description 32 | export function formatDescription(text: string): string { 33 | const trimmed = text.trim(); 34 | return `\n\n${trimmed}`; 35 | } 36 | 37 | // check if string a is prefix of b 38 | export function isPrefixOf(left: string, right: string): boolean { 39 | const lengthLeft = left.length; 40 | const lengthRight = right.length; 41 | if (lengthLeft > lengthRight) { 42 | return false; 43 | } 44 | return (left === right.substring(0, lengthLeft)); 45 | } 46 | 47 | 48 | // get a string from CompletionItem.label type 49 | export function getLabelString(compItemLabel: string | vscode.CompletionItemLabel): string { 50 | return (typeof compItemLabel === 'string') ? compItemLabel : compItemLabel.label; 51 | } 52 | -------------------------------------------------------------------------------- /tree-sitter-bash.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/yamaton/vscode-h2o/b35e037b127748cfda01253c5a15c2fe5f359ae5/tree-sitter-bash.wasm -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "module": "commonjs", 4 | "target": "es6", 5 | "outDir": "out", 6 | "lib": [ 7 | "ES2020" 8 | ], 9 | "sourceMap": true, 10 | "rootDir": "src", 11 | "strict": true /* enable all strict type-checking options */ 12 | /* Additional Checks */ 13 | // "noImplicitReturns": true, /* Report error when not all code paths in function return a value. */ 14 | // "noFallthroughCasesInSwitch": true, /* Report errors for fallthrough cases in switch statement. */ 15 | // "noUnusedParameters": true, /* Report errors on unused parameters. */ 16 | }, 17 | "exclude": [ 18 | "node_modules", 19 | ".vscode-test" 20 | ] 21 | } 22 | --------------------------------------------------------------------------------