From 65527f279ac9223c42f3bfe0ff4901c378d9cb62 Mon Sep 17 00:00:00 2001 From: Sacha Weatherstone Date: Thu, 16 Nov 2023 10:09:37 +1000 Subject: [PATCH] Repo cleanup --- .vscode/extensions.json | 4 +- .vscode/settings.json | 9 +- .vscode/workspace.json | 5 - biome.json | 18 + package.json | 23 +- pnpm-lock.yaml | 786 ++++++++++++++++-- rome.json | 23 - .../{iBleConnection.ts => bleConnection.ts} | 26 +- .../{iHttpConnection.ts => httpConnection.ts} | 6 +- ...erialConnection.ts => serialConnection.ts} | 4 +- src/client.ts | 26 +- src/constants.ts | 8 +- src/index.ts | 16 +- src/{iMeshDevice.ts => meshDevice.ts} | 29 +- src/types.ts | 10 +- src/utils/queue.ts | 10 +- src/utils/xmodem.ts | 8 +- 17 files changed, 800 insertions(+), 211 deletions(-) delete mode 100644 .vscode/workspace.json create mode 100644 biome.json delete mode 100644 rome.json rename src/adapters/{iBleConnection.ts => bleConnection.ts} (93%) rename src/adapters/{iHttpConnection.ts => httpConnection.ts} (97%) rename src/adapters/{iSerialConnection.ts => serialConnection.ts} (98%) rename src/{iMeshDevice.ts => meshDevice.ts} (98%) diff --git a/.vscode/extensions.json b/.vscode/extensions.json index ef2cec8..699ed73 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -1,5 +1,3 @@ { - "recommendations": [ - "rome.rome" - ] + "recommendations": ["biomejs.biome"] } diff --git a/.vscode/settings.json b/.vscode/settings.json index 943fd92..a71cfe3 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,7 +1,4 @@ { - "editor.defaultFormatter": "rome.rome", - "editor.formatOnSave": true, - "[typescript]": { - "editor.defaultFormatter": "rome.rome" - } -} + "editor.defaultFormatter": "biomejs.biome", + "editor.formatOnSave": true +} \ No newline at end of file diff --git a/.vscode/workspace.json b/.vscode/workspace.json deleted file mode 100644 index 371cd73..0000000 --- a/.vscode/workspace.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "settings": { - "editor.formatOnSave": true - } -} diff --git a/biome.json b/biome.json new file mode 100644 index 0000000..c155f23 --- /dev/null +++ b/biome.json @@ -0,0 +1,18 @@ +{ + "$schema": "https://biomejs.dev/schemas/1.3.3/schema.json", + "formatter": { + "enabled": true, + "indentStyle": "space", + "indentWidth": 2 + }, + "organizeImports": { + "enabled": true + }, + "linter": { + "enabled": true, + "rules": { + "all": true + + } + } +} diff --git a/package.json b/package.json index 5f9d1f4..ff82166 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@meshtastic/meshtasticjs", - "version": "2.2.12-0", + "version": "2.2.13-0", "description": "Browser library for interfacing with meshtastic devices", "license": "GPL-3.0-only", "scripts": { @@ -24,10 +24,7 @@ "types": "./types/index.d.ts" } }, - "files": [ - "dist", - ".npmrc" - ], + "files": ["dist", ".npmrc"], "types": "dist/index.d.ts", "bugs": { "url": "https://github.com/meshtastic/js/issues" @@ -37,19 +34,19 @@ "url": "https://github.com/meshtastic/js.git" }, "dependencies": { - "@buf/meshtastic_protobufs.bufbuild_es": "1.3.3-20231023204739-5cff000260c7.1", - "@bufbuild/protobuf": "^1.4.0", + "@buf/meshtastic_protobufs.bufbuild_es": "1.4.2-20231115125959-252a144b0286.1", + "@bufbuild/protobuf": "^1.4.2", + "biome": "^0.3.3", "crc": "^4.3.2", "sub-events": "^1.9.0", "tslib": "^2.6.2", "tslog": "^4.9.2" }, "devDependencies": { - "@types/node": "^20.8.8", - "@types/w3c-web-serial": "^1.0.5", - "@types/web-bluetooth": "^0.0.19", - "rome": "^12.1.3", - "typedoc": "^0.25.2", + "@types/node": "^20.9.0", + "@types/w3c-web-serial": "^1.0.6", + "@types/web-bluetooth": "^0.0.20", + "typedoc": "^0.25.3", "typescript": "^5.2.2" } -} \ No newline at end of file +} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index abd7753..d6d4795 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -6,11 +6,14 @@ settings: dependencies: '@buf/meshtastic_protobufs.bufbuild_es': - specifier: 1.3.3-20231023204739-5cff000260c7.1 - version: 1.3.3-20231023204739-5cff000260c7.1(@bufbuild/protobuf@1.4.0) + specifier: 1.4.2-20231115125959-252a144b0286.1 + version: 1.4.2-20231115125959-252a144b0286.1(@bufbuild/protobuf@1.4.2) '@bufbuild/protobuf': - specifier: ^1.4.0 - version: 1.4.0 + specifier: ^1.4.2 + version: 1.4.2 + biome: + specifier: ^0.3.3 + version: 0.3.3 crc: specifier: ^4.3.2 version: 4.3.2 @@ -26,107 +29,138 @@ dependencies: devDependencies: '@types/node': - specifier: ^20.8.8 - version: 20.8.8 + specifier: ^20.9.0 + version: 20.9.0 '@types/w3c-web-serial': - specifier: ^1.0.5 - version: 1.0.5 + specifier: ^1.0.6 + version: 1.0.6 '@types/web-bluetooth': - specifier: ^0.0.19 - version: 0.0.19 - rome: - specifier: ^12.1.3 - version: 12.1.3 + specifier: ^0.0.20 + version: 0.0.20 typedoc: - specifier: ^0.25.2 - version: 0.25.2(typescript@5.2.2) + specifier: ^0.25.3 + version: 0.25.3(typescript@5.2.2) typescript: specifier: ^5.2.2 version: 5.2.2 packages: - /@buf/meshtastic_protobufs.bufbuild_es@1.3.3-20231023204739-5cff000260c7.1(@bufbuild/protobuf@1.4.0): - resolution: {registry: https://buf.build/gen/npm/v1, tarball: https://buf.build/gen/npm/v1/@buf/meshtastic_protobufs.bufbuild_es/-/meshtastic_protobufs.bufbuild_es-1.3.3-20231023204739-5cff000260c7.1.tgz} + /@buf/meshtastic_protobufs.bufbuild_es@1.4.2-20231115125959-252a144b0286.1(@bufbuild/protobuf@1.4.2): + resolution: {registry: https://buf.build/gen/npm/v1, tarball: https://buf.build/gen/npm/v1/@buf/meshtastic_protobufs.bufbuild_es/-/meshtastic_protobufs.bufbuild_es-1.4.2-20231115125959-252a144b0286.1.tgz} peerDependencies: - '@bufbuild/protobuf': ^1.3.3 + '@bufbuild/protobuf': ^1.4.2 dependencies: - '@bufbuild/protobuf': 1.4.0 + '@bufbuild/protobuf': 1.4.2 dev: false - /@bufbuild/protobuf@1.4.0: - resolution: {integrity: sha512-urGGNsMG8YIyuhsjLFkx41CkAILFnUz9vHaUWvzOnzeoS2DykhSkUEpqTbf9cxG0Vzjmk2rl5ttmLwE0rbQyow==} + /@bufbuild/protobuf@1.4.2: + resolution: {integrity: sha512-JyEH8Z+OD5Sc2opSg86qMHn1EM1Sa+zj/Tc0ovxdwk56ByVNONJSabuCUbLQp+eKN3rWNfrho0X+3SEqEPXIow==} dev: false - /@rometools/cli-darwin-arm64@12.1.3: - resolution: {integrity: sha512-AmFTUDYjBuEGQp/Wwps+2cqUr+qhR7gyXAUnkL5psCuNCz3807TrUq/ecOoct5MIavGJTH6R4aaSL6+f+VlBEg==} - cpu: [arm64] - os: [darwin] - requiresBuild: true + /@types/node@20.9.0: + resolution: {integrity: sha512-nekiGu2NDb1BcVofVcEKMIwzlx4NjHlcjhoxxKBNLtz15Y1z7MYf549DFvkHSId02Ax6kGwWntIBPC3l/JZcmw==} + dependencies: + undici-types: 5.26.5 dev: true - optional: true - /@rometools/cli-darwin-x64@12.1.3: - resolution: {integrity: sha512-k8MbWna8q4LRlb005N2X+JS1UQ+s3ZLBBvwk4fP8TBxlAJXUz17jLLu/Fi+7DTTEmMhM84TWj4FDKW+rNar28g==} - cpu: [x64] - os: [darwin] - requiresBuild: true + /@types/w3c-web-serial@1.0.6: + resolution: {integrity: sha512-5IlDdQ2C56sCVwc7CUlqT9Axxw+0V/FbWRbErklYIzZ5mKL9s4l7epXHygn+4X7L2nmAPnVvRl55XUVo0760Rg==} dev: true - optional: true - /@rometools/cli-linux-arm64@12.1.3: - resolution: {integrity: sha512-X/uLhJ2/FNA3nu5TiyeNPqiD3OZoFfNfRvw6a3ut0jEREPvEn72NI7WPijH/gxSz55znfQ7UQ6iM4DZumUknJg==} - cpu: [arm64] - os: [linux] - requiresBuild: true + /@types/web-bluetooth@0.0.20: + resolution: {integrity: sha512-g9gZnnXVq7gM7v3tJCWV/qw7w+KeOlSHAhgF9RytFyifW6AF61hdT2ucrYhPq9hLs5JIryeupHV3qGk95dH9ow==} dev: true - optional: true - /@rometools/cli-linux-x64@12.1.3: - resolution: {integrity: sha512-csP17q1eWiUXx9z6Jr/JJPibkplyKIwiWPYNzvPCGE8pHlKhwZj3YHRuu7Dm/4EOqx0XFIuqqWZUYm9bkIC8xg==} - cpu: [x64] - os: [linux] - requiresBuild: true - dev: true - optional: true + /ajv@6.12.6: + resolution: {integrity: sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==} + dependencies: + fast-deep-equal: 3.1.3 + fast-json-stable-stringify: 2.1.0 + json-schema-traverse: 0.4.1 + uri-js: 4.4.1 + dev: false - /@rometools/cli-win32-arm64@12.1.3: - resolution: {integrity: sha512-RymHWeod57EBOJY4P636CgUwYA6BQdkQjh56XKk4pLEHO6X1bFyMet2XL7KlHw5qOTalzuzf5jJqUs+vf3jdXQ==} - cpu: [arm64] - os: [win32] - requiresBuild: true - dev: true - optional: true + /ansi-escapes@1.4.0: + resolution: {integrity: sha512-wiXutNjDUlNEDWHcYH3jtZUhd3c4/VojassD8zHdHCY13xbZy2XbW+NKQwA0tWGBVzDA9qEzYwfoSsWmviidhw==} + engines: {node: '>=0.10.0'} + dev: false - /@rometools/cli-win32-x64@12.1.3: - resolution: {integrity: sha512-yHSKYidqJMV9nADqg78GYA+cZ0hS1twANAjiFibQdXj9aGzD+s/IzIFEIi/U/OBLvWYg/SCw0QVozi2vTlKFDQ==} - cpu: [x64] - os: [win32] - requiresBuild: true + /ansi-regex@2.1.1: + resolution: {integrity: sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==} + engines: {node: '>=0.10.0'} + dev: false + + /ansi-sequence-parser@1.1.1: + resolution: {integrity: sha512-vJXt3yiaUL4UU546s3rPXlsry/RnM730G1+HkpKE012AN0sx1eOrxSu95oKDIonskeLTijMgqWZ3uDEe3NFvyg==} dev: true - optional: true - /@types/node@20.8.8: - resolution: {integrity: sha512-YRsdVxq6OaLfmR9Hy816IMp33xOBjfyOgUd77ehqg96CFywxAPbDbXvAsuN2KVg2HOT8Eh6uAfU+l4WffwPVrQ==} + /ansi-styles@2.2.1: + resolution: {integrity: sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==} + engines: {node: '>=0.10.0'} + dev: false + + /any-promise@1.3.0: + resolution: {integrity: sha512-7UvmKalWRt1wgjL1RrGxoSJW/0QZFIegpeGvZG9kjp8vrRu55XTHbwnqq2GpXm9uLbcuhxm3IqX9OB4MZR1b2A==} + dev: false + + /asn1@0.2.6: + resolution: {integrity: sha512-ix/FxPn0MDjeyJ7i/yoHGFt/EX6LyNbxSEhPPXODPL+KB0VPk86UYfL0lMdy+KCnv+fmvIzySwaK5COwqVbWTQ==} dependencies: - undici-types: 5.25.3 - dev: true + safer-buffer: 2.1.2 + dev: false - /@types/w3c-web-serial@1.0.5: - resolution: {integrity: sha512-gpWNghA1RjPc92puT2HRRRFjv0MDVcpS9yTjJPLwCRU+w1YQTmJommTEL1w7l6Llq5/2cbzH1B4jHx/EP0PcjQ==} - dev: true + /assert-plus@1.0.0: + resolution: {integrity: sha512-NfJ4UzBCcQGLDlQq7nHxH+tv3kyZ0hHQqF5BO6J7tNJeP5do1llPr8dZ8zHonfhAu0PHAdMkSo+8o0wxg9lZWw==} + engines: {node: '>=0.8'} + dev: false - /@types/web-bluetooth@0.0.19: - resolution: {integrity: sha512-0Eoq1m8n3qXnV8tUJpL+Dgk09jJOp7IN1kXuwn65+i1VgxzNRW6sArEDrD9uPe5+wgBp3ZNYMAAtrminQf5RjA==} - dev: true + /asynckit@0.4.0: + resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==} + dev: false - /ansi-sequence-parser@1.1.1: - resolution: {integrity: sha512-vJXt3yiaUL4UU546s3rPXlsry/RnM730G1+HkpKE012AN0sx1eOrxSu95oKDIonskeLTijMgqWZ3uDEe3NFvyg==} - dev: true + /aws-sign2@0.7.0: + resolution: {integrity: sha512-08kcGqnYf/YmjoRhfxyu+CLxBjUtHLXLXX/vUfx9l2LYzG3c1m61nrpyFUZI6zeS+Li/wWMMidD9KgrqtGq3mA==} + dev: false + + /aws4@1.12.0: + resolution: {integrity: sha512-NmWvPnx0F1SfrQbYwOi7OeaNGokp9XhzNioJ/CSBs8Qa4vxug81mhJEAVZwxXuBmYB5KDRfMq/F3RR0BIU7sWg==} + dev: false /balanced-match@1.0.2: resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} - dev: true + + /bcrypt-pbkdf@1.0.2: + resolution: {integrity: sha512-qeFIXtP4MSoi6NLqO12WfqARWWuCKi2Rn/9hJLEmtB5yTNr9DqFWkJRCf2qShWzPeAMRnOgCrq0sg/KLv5ES9w==} + dependencies: + tweetnacl: 0.14.5 + dev: false + + /biome@0.3.3: + resolution: {integrity: sha512-4LXjrQYbn9iTXu9Y4SKT7ABzTV0WnLDHCVSd2fPUOKsy1gQ+E4xPFmlY1zcWexoi0j7fGHItlL6OWA2CZ/yYAQ==} + hasBin: true + dependencies: + bluebird: 3.7.2 + chalk: 1.1.3 + commander: 2.20.3 + editor: 1.0.0 + fs-promise: 0.5.0 + inquirer-promise: 0.0.3 + request-promise: 3.0.0 + untildify: 3.0.3 + user-home: 2.0.0 + dev: false + + /bluebird@3.7.2: + resolution: {integrity: sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==} + dev: false + + /brace-expansion@1.1.11: + resolution: {integrity: sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==} + dependencies: + balanced-match: 1.0.2 + concat-map: 0.0.1 + dev: false /brace-expansion@2.0.1: resolution: {integrity: sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==} @@ -134,6 +168,62 @@ packages: balanced-match: 1.0.2 dev: true + /caseless@0.12.0: + resolution: {integrity: sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw==} + dev: false + + /chalk@1.1.3: + resolution: {integrity: sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==} + engines: {node: '>=0.10.0'} + dependencies: + ansi-styles: 2.2.1 + escape-string-regexp: 1.0.5 + has-ansi: 2.0.0 + strip-ansi: 3.0.1 + supports-color: 2.0.0 + dev: false + + /cli-cursor@1.0.2: + resolution: {integrity: sha512-25tABq090YNKkF6JH7lcwO0zFJTRke4Jcq9iX2nr/Sz0Cjjv4gckmwlW6Ty/aoyFd6z3ysR2hMGC2GFugmBo6A==} + engines: {node: '>=0.10.0'} + dependencies: + restore-cursor: 1.0.1 + dev: false + + /cli-width@1.1.1: + resolution: {integrity: sha512-eMU2akIeEIkCxGXUNmDnJq1KzOIiPnJ+rKqRe6hcxE3vIOPvpMrBYOn/Bl7zNlYJj/zQxXquAnozHUCf9Whnsg==} + dev: false + + /code-point-at@1.1.0: + resolution: {integrity: sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==} + engines: {node: '>=0.10.0'} + dev: false + + /combined-stream@1.0.8: + resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} + engines: {node: '>= 0.8'} + dependencies: + delayed-stream: 1.0.0 + dev: false + + /commander@2.20.3: + resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==} + dev: false + + /concat-map@0.0.1: + resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==} + dev: false + + /core-js@2.6.12: + resolution: {integrity: sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ==} + deprecated: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js. + requiresBuild: true + dev: false + + /core-util-is@1.0.2: + resolution: {integrity: sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ==} + dev: false + /crc@4.3.2: resolution: {integrity: sha512-uGDHf4KLLh2zsHa8D8hIQ1H/HtFQhyHrc0uhHBcoKGol/Xnb+MPYfUMw7cvON6ze/GUESTudKayDcJC5HnJv1A==} engines: {node: '>=12'} @@ -144,10 +234,268 @@ packages: optional: true dev: false + /dashdash@1.14.1: + resolution: {integrity: sha512-jRFi8UDGo6j+odZiEpjazZaWqEal3w/basFjQHQEwVtZJGDpxbH1MeYluwCS8Xq5wmLJooDlMgvVarmWfGM44g==} + engines: {node: '>=0.10'} + dependencies: + assert-plus: 1.0.0 + dev: false + + /delayed-stream@1.0.0: + resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==} + engines: {node: '>=0.4.0'} + dev: false + + /earlgrey-runtime@0.1.2: + resolution: {integrity: sha512-T4qoScXi5TwALDv8nlGTvOuCT8jXcKcxtO8qVdqv46IA2GHJfQzwoBPbkOmORnyhu3A98cVVuhWLsM2CzPljJg==} + dependencies: + core-js: 2.6.12 + kaiser: 0.0.4 + lodash: 4.17.21 + regenerator-runtime: 0.9.6 + dev: false + + /ecc-jsbn@0.1.2: + resolution: {integrity: sha512-eh9O+hwRHNbG4BLTjEl3nw044CkGm5X6LoaCf7LPp7UU8Qrt47JYNi6nPX8xjW97TKGKm1ouctg0QSpZe9qrnw==} + dependencies: + jsbn: 0.1.1 + safer-buffer: 2.1.2 + dev: false + + /editor@1.0.0: + resolution: {integrity: sha512-SoRmbGStwNYHgKfjOrX2L0mUvp9bUVv0uPppZSOMAntEbcFtoC3MKF5b3T6HQPXKIV+QGY3xPO3JK5it5lVkuw==} + dev: false + + /escape-string-regexp@1.0.5: + resolution: {integrity: sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==} + engines: {node: '>=0.8.0'} + dev: false + + /exit-hook@1.1.1: + resolution: {integrity: sha512-MsG3prOVw1WtLXAZbM3KiYtooKR1LvxHh3VHsVtIy0uiUu8usxgB/94DP2HxtD/661lLdB6yzQ09lGJSQr6nkg==} + engines: {node: '>=0.10.0'} + dev: false + + /extend@3.0.2: + resolution: {integrity: sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==} + dev: false + + /extsprintf@1.3.0: + resolution: {integrity: sha512-11Ndz7Nv+mvAC1j0ktTa7fAb0vLyGGX+rMHNBYQviQDGU0Hw7lhctJANqbPhu9nV9/izT/IntTgZ7Im/9LJs9g==} + engines: {'0': node >=0.6.0} + dev: false + + /fast-deep-equal@3.1.3: + resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} + dev: false + + /fast-json-stable-stringify@2.1.0: + resolution: {integrity: sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==} + dev: false + + /figures@1.7.0: + resolution: {integrity: sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ==} + engines: {node: '>=0.10.0'} + dependencies: + escape-string-regexp: 1.0.5 + object-assign: 4.1.1 + dev: false + + /forever-agent@0.6.1: + resolution: {integrity: sha512-j0KLYPhm6zeac4lz3oJ3o65qvgQCcPubiyotZrXqEaG4hNagNYO8qdlUrX5vwqv9ohqeT/Z3j6+yW067yWWdUw==} + dev: false + + /form-data@2.3.3: + resolution: {integrity: sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==} + engines: {node: '>= 0.12'} + dependencies: + asynckit: 0.4.0 + combined-stream: 1.0.8 + mime-types: 2.1.35 + dev: false + + /fs-extra@0.26.7: + resolution: {integrity: sha512-waKu+1KumRhYv8D8gMRCKJGAMI9pRnPuEb1mvgYD0f7wBscg+h6bW4FDTmEZhB9VKxvoTtxW+Y7bnIlB7zja6Q==} + dependencies: + graceful-fs: 4.2.11 + jsonfile: 2.4.0 + klaw: 1.3.1 + path-is-absolute: 1.0.1 + rimraf: 2.7.1 + dev: false + + /fs-promise@0.5.0: + resolution: {integrity: sha512-Y+4F4ujhEcayCJt6JmzcOun9MYGQwz+bVUiuBmTkJImhBHKpBvmVPZR9wtfiF7k3ffwAOAuurygQe+cPLSFQhw==} + deprecated: Use mz or fs-extra^3.0 with Promise Support + dependencies: + any-promise: 1.3.0 + fs-extra: 0.26.7 + mz: 2.7.0 + thenify-all: 1.6.0 + dev: false + + /fs.realpath@1.0.0: + resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} + dev: false + + /getpass@0.1.7: + resolution: {integrity: sha512-0fzj9JxOLfJ+XGLhR8ze3unN0KZCgZwiSSDz168VERjK8Wl8kVSdcu2kspd4s4wtAa1y/qrVRiAA0WclVsu0ng==} + dependencies: + assert-plus: 1.0.0 + dev: false + + /glob@7.2.3: + resolution: {integrity: sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==} + dependencies: + fs.realpath: 1.0.0 + inflight: 1.0.6 + inherits: 2.0.4 + minimatch: 3.1.2 + once: 1.4.0 + path-is-absolute: 1.0.1 + dev: false + + /graceful-fs@4.2.11: + resolution: {integrity: sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==} + dev: false + + /har-schema@2.0.0: + resolution: {integrity: sha512-Oqluz6zhGX8cyRaTQlFMPw80bSJVG2x/cFb8ZPhUILGgHka9SsokCCOQgpveePerqidZOrT14ipqfJb7ILcW5Q==} + engines: {node: '>=4'} + dev: false + + /har-validator@5.1.5: + resolution: {integrity: sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w==} + engines: {node: '>=6'} + deprecated: this library is no longer supported + dependencies: + ajv: 6.12.6 + har-schema: 2.0.0 + dev: false + + /has-ansi@2.0.0: + resolution: {integrity: sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==} + engines: {node: '>=0.10.0'} + dependencies: + ansi-regex: 2.1.1 + dev: false + + /http-signature@1.2.0: + resolution: {integrity: sha512-CAbnr6Rz4CYQkLYUtSNXxQPUH2gK8f3iWexVlsnMeD+GjlsQ0Xsy1cOX+mN3dtxYomRy21CiOzU8Uhw6OwncEQ==} + engines: {node: '>=0.8', npm: '>=1.3.7'} + dependencies: + assert-plus: 1.0.0 + jsprim: 1.4.2 + sshpk: 1.18.0 + dev: false + + /inflight@1.0.6: + resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==} + dependencies: + once: 1.4.0 + wrappy: 1.0.2 + dev: false + + /inherits@2.0.4: + resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} + dev: false + + /inquirer-promise@0.0.3: + resolution: {integrity: sha512-82CQX586JAV9GAgU9yXZsMDs+NorjA0nLhkfFx9+PReyOnuoHRbHrC1Z90sS95bFJI1Tm1gzMObuE0HabzkJpg==} + dependencies: + earlgrey-runtime: 0.1.2 + inquirer: 0.11.4 + dev: false + + /inquirer@0.11.4: + resolution: {integrity: sha512-QR+2TW90jnKk9LUUtbcA3yQXKt2rDEKMh6+BAZQIeumtzHexnwVLdPakSslGijXYLJCzFv7GMXbFCn0pA00EUw==} + dependencies: + ansi-escapes: 1.4.0 + ansi-regex: 2.1.1 + chalk: 1.1.3 + cli-cursor: 1.0.2 + cli-width: 1.1.1 + figures: 1.7.0 + lodash: 3.10.1 + readline2: 1.0.1 + run-async: 0.1.0 + rx-lite: 3.1.2 + string-width: 1.0.2 + strip-ansi: 3.0.1 + through: 2.3.8 + dev: false + + /is-fullwidth-code-point@1.0.0: + resolution: {integrity: sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==} + engines: {node: '>=0.10.0'} + dependencies: + number-is-nan: 1.0.1 + dev: false + + /is-typedarray@1.0.0: + resolution: {integrity: sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA==} + dev: false + + /isstream@0.1.2: + resolution: {integrity: sha512-Yljz7ffyPbrLpLngrMtZ7NduUgVvi6wG9RJ9IUcyCd59YQ911PBJphODUcbOVbqYfxe1wuYf/LJ8PauMRwsM/g==} + dev: false + + /jsbn@0.1.1: + resolution: {integrity: sha512-UVU9dibq2JcFWxQPA6KCqj5O42VOmAY3zQUfEKxU0KpTGXwNoCjkX1e13eHNvw/xPynt6pU0rZ1htjWTNTSXsg==} + dev: false + + /json-schema-traverse@0.4.1: + resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==} + dev: false + + /json-schema@0.4.0: + resolution: {integrity: sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA==} + dev: false + + /json-stringify-safe@5.0.1: + resolution: {integrity: sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==} + dev: false + /jsonc-parser@3.2.0: resolution: {integrity: sha512-gfFQZrcTc8CnKXp6Y4/CBT3fTc0OVuDofpre4aEeEpSBPV5X5v4+Vmx+8snU7RLPrNHPKSgLxGo9YuQzz20o+w==} dev: true + /jsonfile@2.4.0: + resolution: {integrity: sha512-PKllAqbgLgxHaj8TElYymKCAgrASebJrWpTnEkOaTowt23VKXXN0sUeriJ+eh7y6ufb/CC5ap11pz71/cM0hUw==} + optionalDependencies: + graceful-fs: 4.2.11 + dev: false + + /jsprim@1.4.2: + resolution: {integrity: sha512-P2bSOMAc/ciLz6DzgjVlGJP9+BrJWu5UDGK70C2iweC5QBIeFf0ZXRvGjEj2uYgrY2MkAAhsSWHDWlFtEroZWw==} + engines: {node: '>=0.6.0'} + dependencies: + assert-plus: 1.0.0 + extsprintf: 1.3.0 + json-schema: 0.4.0 + verror: 1.10.0 + dev: false + + /kaiser@0.0.4: + resolution: {integrity: sha512-m8ju+rmBqvclZmyrOXgGGhOYSjKJK6RN1NhqEltemY87UqZOxEkizg9TOy1vQSyJ01Wx6SAPuuN0iO2Mgislvw==} + dependencies: + earlgrey-runtime: 0.1.2 + dev: false + + /klaw@1.3.1: + resolution: {integrity: sha512-TED5xi9gGQjGpNnvRWknrwAB1eL5GciPfVFOt3Vk1OJCVDQbzuSfrF3hkUQKlsgKrG1F+0t5W0m+Fje1jIt8rw==} + optionalDependencies: + graceful-fs: 4.2.11 + dev: false + + /lodash@3.10.1: + resolution: {integrity: sha512-9mDDwqVIma6OZX79ZlDACZl8sBm0TEnkf99zV3iMA4GzkIT/9hiqP5mY0HoT1iNLCrKc/R1HByV+yJfRWVJryQ==} + dev: false + + /lodash@4.17.21: + resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==} + dev: false + /lunr@2.3.9: resolution: {integrity: sha512-zTU3DaZaF3Rt9rhN3uBMGQD3dD2/vFQqnvZCDv4dl5iOzq2IZQqTxu90r4E5J+nP70J3ilqVCrbho2eWaeW8Ow==} dev: true @@ -158,6 +506,24 @@ packages: hasBin: true dev: true + /mime-db@1.52.0: + resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} + engines: {node: '>= 0.6'} + dev: false + + /mime-types@2.1.35: + resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} + engines: {node: '>= 0.6'} + dependencies: + mime-db: 1.52.0 + dev: false + + /minimatch@3.1.2: + resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==} + dependencies: + brace-expansion: 1.1.11 + dev: false + /minimatch@9.0.3: resolution: {integrity: sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg==} engines: {node: '>=16 || 14 >=14.17'} @@ -165,19 +531,152 @@ packages: brace-expansion: 2.0.1 dev: true - /rome@12.1.3: - resolution: {integrity: sha512-e+ff72hxDpe/t5/Us7YRBVw3PBET7SeczTQNn6tvrWdrCaAw3qOukQQ+tDCkyFtS4yGsnhjrJbm43ctNbz27Yg==} - engines: {node: '>=14.*'} + /mute-stream@0.0.5: + resolution: {integrity: sha512-EbrziT4s8cWPmzr47eYVW3wimS4HsvlnV5ri1xw1aR6JQo/OrJX5rkl32K/QQHdxeabJETtfeaROGhd8W7uBgg==} + dev: false + + /mz@2.7.0: + resolution: {integrity: sha512-z81GNO7nnYMEhrGh9LeymoE4+Yr0Wn5McHIZMK5cfQCl+NDX08sCZgUc9/6MHni9IWuFLm1Z3HTCXu2z9fN62Q==} + dependencies: + any-promise: 1.3.0 + object-assign: 4.1.1 + thenify-all: 1.6.0 + dev: false + + /number-is-nan@1.0.1: + resolution: {integrity: sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==} + engines: {node: '>=0.10.0'} + dev: false + + /oauth-sign@0.9.0: + resolution: {integrity: sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==} + dev: false + + /object-assign@4.1.1: + resolution: {integrity: sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==} + engines: {node: '>=0.10.0'} + dev: false + + /once@1.4.0: + resolution: {integrity: sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==} + dependencies: + wrappy: 1.0.2 + dev: false + + /onetime@1.1.0: + resolution: {integrity: sha512-GZ+g4jayMqzCRMgB2sol7GiCLjKfS1PINkjmx8spcKce1LiVqcbQreXwqs2YAFXC6R03VIG28ZS31t8M866v6A==} + engines: {node: '>=0.10.0'} + dev: false + + /os-homedir@1.0.2: + resolution: {integrity: sha512-B5JU3cabzk8c67mRRd3ECmROafjYMXbuzlwtqdM8IbS8ktlTix8aFGb2bAGKrSRIlnfKwovGUUr72JUPyOb6kQ==} + engines: {node: '>=0.10.0'} + dev: false + + /path-is-absolute@1.0.1: + resolution: {integrity: sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==} + engines: {node: '>=0.10.0'} + dev: false + + /performance-now@2.1.0: + resolution: {integrity: sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==} + dev: false + + /psl@1.9.0: + resolution: {integrity: sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag==} + dev: false + + /punycode@2.3.1: + resolution: {integrity: sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==} + engines: {node: '>=6'} + dev: false + + /qs@6.5.3: + resolution: {integrity: sha512-qxXIEh4pCGfHICj1mAJQ2/2XVZkjCDTcEgfoSQxc/fYivUZxTkk7L3bDBJSoNrEzXI17oUO5Dp07ktqE5KzczA==} + engines: {node: '>=0.6'} + dev: false + + /readline2@1.0.1: + resolution: {integrity: sha512-8/td4MmwUB6PkZUbV25uKz7dfrmjYWxsW8DVfibWdlHRk/l/DfHKn4pU+dfcoGLFgWOdyGCzINRQD7jn+Bv+/g==} + dependencies: + code-point-at: 1.1.0 + is-fullwidth-code-point: 1.0.0 + mute-stream: 0.0.5 + dev: false + + /regenerator-runtime@0.9.6: + resolution: {integrity: sha512-D0Y/JJ4VhusyMOd/o25a3jdUqN/bC85EFsaoL9Oqmy/O4efCh+xhp7yj2EEOsj974qvMkcW8AwUzJ1jB/MbxCw==} + dev: false + + /request-promise@3.0.0: + resolution: {integrity: sha512-wVGUX+BoKxYsavTA72i6qHcyLbjzM4LR4y/AmDCqlbuMAursZdDWO7PmgbGAUvD2SeEJ5iB99VSq/U51i/DNbw==} + engines: {node: '>=0.10.0'} + deprecated: request-promise has been deprecated because it extends the now deprecated request package, see https://github.com/request/request/issues/3142 + dependencies: + bluebird: 3.7.2 + lodash: 4.17.21 + request: 2.88.2 + dev: false + + /request@2.88.2: + resolution: {integrity: sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw==} + engines: {node: '>= 6'} + deprecated: request has been deprecated, see https://github.com/request/request/issues/3142 + dependencies: + aws-sign2: 0.7.0 + aws4: 1.12.0 + caseless: 0.12.0 + combined-stream: 1.0.8 + extend: 3.0.2 + forever-agent: 0.6.1 + form-data: 2.3.3 + har-validator: 5.1.5 + http-signature: 1.2.0 + is-typedarray: 1.0.0 + isstream: 0.1.2 + json-stringify-safe: 5.0.1 + mime-types: 2.1.35 + oauth-sign: 0.9.0 + performance-now: 2.1.0 + qs: 6.5.3 + safe-buffer: 5.2.1 + tough-cookie: 2.5.0 + tunnel-agent: 0.6.0 + uuid: 3.4.0 + dev: false + + /restore-cursor@1.0.1: + resolution: {integrity: sha512-reSjH4HuiFlxlaBaFCiS6O76ZGG2ygKoSlCsipKdaZuKSPx/+bt9mULkn4l0asVzbEfQQmXRg6Wp6gv6m0wElw==} + engines: {node: '>=0.10.0'} + dependencies: + exit-hook: 1.1.1 + onetime: 1.1.0 + dev: false + + /rimraf@2.7.1: + resolution: {integrity: sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==} hasBin: true - requiresBuild: true - optionalDependencies: - '@rometools/cli-darwin-arm64': 12.1.3 - '@rometools/cli-darwin-x64': 12.1.3 - '@rometools/cli-linux-arm64': 12.1.3 - '@rometools/cli-linux-x64': 12.1.3 - '@rometools/cli-win32-arm64': 12.1.3 - '@rometools/cli-win32-x64': 12.1.3 - dev: true + dependencies: + glob: 7.2.3 + dev: false + + /run-async@0.1.0: + resolution: {integrity: sha512-qOX+w+IxFgpUpJfkv2oGN0+ExPs68F4sZHfaRRx4dDexAQkG83atugKVEylyT5ARees3HBbfmuvnjbrd8j9Wjw==} + dependencies: + once: 1.4.0 + dev: false + + /rx-lite@3.1.2: + resolution: {integrity: sha512-1I1+G2gteLB8Tkt8YI1sJvSIfa0lWuRtC8GjvtyPBcLSF5jBCCJJqKrpER5JU5r6Bhe+i9/pK3VMuUcXu0kdwQ==} + dev: false + + /safe-buffer@5.2.1: + resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} + dev: false + + /safer-buffer@2.1.2: + resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} + dev: false /shiki@0.14.5: resolution: {integrity: sha512-1gCAYOcmCFONmErGTrS1fjzJLA7MGZmKzrBNX7apqSwhyITJg2O102uFzXUeBxNnEkDA9vHIKLyeKq0V083vIw==} @@ -188,11 +687,73 @@ packages: vscode-textmate: 8.0.0 dev: true + /sshpk@1.18.0: + resolution: {integrity: sha512-2p2KJZTSqQ/I3+HX42EpYOa2l3f8Erv8MWKsy2I9uf4wA7yFIkXRffYdsx86y6z4vHtV8u7g+pPlr8/4ouAxsQ==} + engines: {node: '>=0.10.0'} + hasBin: true + dependencies: + asn1: 0.2.6 + assert-plus: 1.0.0 + bcrypt-pbkdf: 1.0.2 + dashdash: 1.14.1 + ecc-jsbn: 0.1.2 + getpass: 0.1.7 + jsbn: 0.1.1 + safer-buffer: 2.1.2 + tweetnacl: 0.14.5 + dev: false + + /string-width@1.0.2: + resolution: {integrity: sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==} + engines: {node: '>=0.10.0'} + dependencies: + code-point-at: 1.1.0 + is-fullwidth-code-point: 1.0.0 + strip-ansi: 3.0.1 + dev: false + + /strip-ansi@3.0.1: + resolution: {integrity: sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==} + engines: {node: '>=0.10.0'} + dependencies: + ansi-regex: 2.1.1 + dev: false + /sub-events@1.9.0: resolution: {integrity: sha512-dnFBayilG9Ku0k/lNs1Y7WV4kv91+ovCoeBV3uIYrY49DylvBb6z9d9ED2ctcrvX2YlReFalpCgJNtSgmrOaJg==} engines: {node: '>=10.0.0'} dev: false + /supports-color@2.0.0: + resolution: {integrity: sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==} + engines: {node: '>=0.8.0'} + dev: false + + /thenify-all@1.6.0: + resolution: {integrity: sha512-RNxQH/qI8/t3thXJDwcstUO4zeqo64+Uy/+sNVRBx4Xn2OX+OZ9oP+iJnNFqplFra2ZUVeKCSa2oVWi3T4uVmA==} + engines: {node: '>=0.8'} + dependencies: + thenify: 3.3.1 + dev: false + + /thenify@3.3.1: + resolution: {integrity: sha512-RVZSIV5IG10Hk3enotrhvz0T9em6cyHBLkH/YAZuKqd8hRkKhSfCGIcP2KUY0EPxndzANBmNllzWPwak+bheSw==} + dependencies: + any-promise: 1.3.0 + dev: false + + /through@2.3.8: + resolution: {integrity: sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==} + dev: false + + /tough-cookie@2.5.0: + resolution: {integrity: sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g==} + engines: {node: '>=0.8'} + dependencies: + psl: 1.9.0 + punycode: 2.3.1 + dev: false + /tslib@2.6.2: resolution: {integrity: sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==} dev: false @@ -202,8 +763,18 @@ packages: engines: {node: '>=16'} dev: false - /typedoc@0.25.2(typescript@5.2.2): - resolution: {integrity: sha512-286F7BeATBiWe/qC4PCOCKlSTwfnsLbC/4cZ68oGBbvAqb9vV33quEOXx7q176OXotD+JdEerdQ1OZGJ818lnA==} + /tunnel-agent@0.6.0: + resolution: {integrity: sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==} + dependencies: + safe-buffer: 5.2.1 + dev: false + + /tweetnacl@0.14.5: + resolution: {integrity: sha512-KXXFFdAbFXY4geFIwoyNK+f5Z1b7swfXABfL7HXCmoIWMKU3dmS26672A4EeQtDzLKy7SXmfBu51JolvEKwtGA==} + dev: false + + /typedoc@0.25.3(typescript@5.2.2): + resolution: {integrity: sha512-Ow8Bo7uY1Lwy7GTmphRIMEo6IOZ+yYUyrc8n5KXIZg1svpqhZSWgni2ZrDhe+wLosFS8yswowUzljTAV/3jmWw==} engines: {node: '>= 16'} hasBin: true peerDependencies: @@ -222,10 +793,43 @@ packages: hasBin: true dev: true - /undici-types@5.25.3: - resolution: {integrity: sha512-Ga1jfYwRn7+cP9v8auvEXN1rX3sWqlayd4HP7OKk4mZWylEmu3KzXDUGrQUN6Ol7qo1gPvB2e5gX6udnyEPgdA==} + /undici-types@5.26.5: + resolution: {integrity: sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA==} dev: true + /untildify@3.0.3: + resolution: {integrity: sha512-iSk/J8efr8uPT/Z4eSUywnqyrQU7DSdMfdqK4iWEaUVVmcP5JcnpRqmVMwcwcnmI1ATFNgC5V90u09tBynNFKA==} + engines: {node: '>=4'} + dev: false + + /uri-js@4.4.1: + resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==} + dependencies: + punycode: 2.3.1 + dev: false + + /user-home@2.0.0: + resolution: {integrity: sha512-KMWqdlOcjCYdtIJpicDSFBQ8nFwS2i9sslAd6f4+CBGcU4gist2REnr2fxj2YocvJFxSF3ZOHLYLVZnUxv4BZQ==} + engines: {node: '>=0.10.0'} + dependencies: + os-homedir: 1.0.2 + dev: false + + /uuid@3.4.0: + resolution: {integrity: sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==} + deprecated: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. + hasBin: true + dev: false + + /verror@1.10.0: + resolution: {integrity: sha512-ZZKSmDAEFOijERBLkmYfJ+vmk3w+7hOLYDNkRCuRuMJGEmqYNCNLyBBFwWKVMhfwaEF3WOd0Zlw86U/WC/+nYw==} + engines: {'0': node >=0.6.0} + dependencies: + assert-plus: 1.0.0 + core-util-is: 1.0.2 + extsprintf: 1.3.0 + dev: false + /vscode-oniguruma@1.7.0: resolution: {integrity: sha512-L9WMGRfrjOhgHSdOYgCt/yRMsXzLDJSL7BPrOZt73gU0iWO4mpqzqQzOz5srxqTvMBaR0XZTSrVWo4j55Rc6cA==} dev: true @@ -233,3 +837,7 @@ packages: /vscode-textmate@8.0.0: resolution: {integrity: sha512-AFbieoL7a5LMqcnOF04ji+rpXadgOXnZsxQr//r83kLPr7biP7am3g9zbaZIaBGwBRWeSvoMD4mgPdX3e4NWBg==} dev: true + + /wrappy@1.0.2: + resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} + dev: false diff --git a/rome.json b/rome.json deleted file mode 100644 index 1f5dbcd..0000000 --- a/rome.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "$schema": "./node_modules/rome/configuration_schema.json", - "formatter": { - "enabled": true, - "indentStyle": "space", - "indentSize": 2 - }, - "linter": { - "enabled": true, - "rules": { - "recommended": true - } - }, - "organizeImports": { - "enabled": true - }, - "files": { - "ignore": [ - "node_modules", - "dist" - ] - } -} \ No newline at end of file diff --git a/src/adapters/iBleConnection.ts b/src/adapters/bleConnection.ts similarity index 93% rename from src/adapters/iBleConnection.ts rename to src/adapters/bleConnection.ts index c3466c4..c00e18f 100755 --- a/src/adapters/iBleConnection.ts +++ b/src/adapters/bleConnection.ts @@ -1,15 +1,15 @@ import { - fromNumUUID, - fromRadioUUID, - serviceUUID, - toRadioUUID, + FromNumUuid, + FromRadioUuid, + ServiceUuid, + ToRadioUuid, } from "../constants.js"; -import { IMeshDevice } from "../iMeshDevice.js"; +import { MeshDevice } from "../meshDevice.js"; import { Types } from "../index.js"; import { typedArrayToBuffer } from "../utils/general.js"; /** Allows to connect to a Meshtastic device via bluetooth */ -export class IBLEConnection extends IMeshDevice { +export class BleConnection extends MeshDevice { /** Defines the connection type as ble */ public connType: Types.ConnectionTypeName; @@ -79,7 +79,7 @@ export class IBLEConnection extends IMeshDevice { public getDevice(filter?: RequestDeviceOptions): Promise { return navigator.bluetooth.requestDevice( filter ?? { - filters: [{ services: [serviceUUID] }], + filters: [{ services: [ServiceUuid] }], }, ); } @@ -90,7 +90,7 @@ export class IBLEConnection extends IMeshDevice { public async connect({ device, deviceFilter, - }: Types.BLEConnectionParameters): Promise { + }: Types.BleConnectionParameters): Promise { /** Set device state to connecting */ this.updateDeviceStatus(Types.DeviceStatusEnum.DEVICE_CONNECTING); @@ -126,7 +126,7 @@ export class IBLEConnection extends IMeshDevice { ); }); - await this.GATTServer?.getPrimaryService(serviceUUID) + await this.GATTServer?.getPrimaryService(ServiceUuid) .then((service) => { this.log.info( Types.Emitter[Types.Emitter.connect], @@ -141,7 +141,7 @@ export class IBLEConnection extends IMeshDevice { ); }); - [toRadioUUID, fromRadioUUID, fromNumUUID].map(async (uuid) => { + [ToRadioUuid, FromRadioUuid, FromNumUuid].map(async (uuid) => { await this.service ?.getCharacteristic(uuid) .then((characteristic) => { @@ -150,13 +150,13 @@ export class IBLEConnection extends IMeshDevice { `✅ Got Characteristic ${characteristic.uuid} for device: ${characteristic.uuid}`, ); switch (uuid) { - case toRadioUUID: + case ToRadioUuid: this.toRadioCharacteristic = characteristic; break; - case fromRadioUUID: + case FromRadioUuid: this.fromRadioCharacteristic = characteristic; break; - case fromNumUUID: + case FromNumUuid: this.fromNumCharacteristic = characteristic; break; } diff --git a/src/adapters/iHttpConnection.ts b/src/adapters/httpConnection.ts similarity index 97% rename from src/adapters/iHttpConnection.ts rename to src/adapters/httpConnection.ts index 4d53499..1194407 100755 --- a/src/adapters/iHttpConnection.ts +++ b/src/adapters/httpConnection.ts @@ -1,9 +1,9 @@ -import { IMeshDevice } from "../iMeshDevice.js"; +import { MeshDevice } from "../meshDevice.js"; import { Types } from "../index.js"; import { typedArrayToBuffer } from "../utils/general.js"; /** Allows to connect to a Meshtastic device over HTTP(S) */ -export class IHTTPConnection extends IMeshDevice { +export class HttpConnection extends MeshDevice { /** Defines the connection type as http */ public connType: Types.ConnectionTypeName; @@ -45,7 +45,7 @@ export class IHTTPConnection extends IMeshDevice { fetchInterval = 3000, receiveBatchRequests = false, tls = false, - }: Types.HTTPConnectionParameters): Promise { + }: Types.HttpConnectionParameters): Promise { this.updateDeviceStatus(Types.DeviceStatusEnum.DEVICE_CONNECTING); this.receiveBatchRequests = receiveBatchRequests; diff --git a/src/adapters/iSerialConnection.ts b/src/adapters/serialConnection.ts similarity index 98% rename from src/adapters/iSerialConnection.ts rename to src/adapters/serialConnection.ts index 1d3b5a4..4c39795 100644 --- a/src/adapters/iSerialConnection.ts +++ b/src/adapters/serialConnection.ts @@ -1,11 +1,11 @@ import { SubEvent } from "sub-events"; -import { IMeshDevice } from "../iMeshDevice.js"; +import { MeshDevice } from "../meshDevice.js"; import { Types } from "../index.js"; import { transformHandler } from "../utils/transformHandler.js"; /** Allows to connect to a Meshtastic device over WebSerial */ -export class ISerialConnection extends IMeshDevice { +export class SerialConnection extends MeshDevice { /** Defines the connection type as serial */ public connType: Types.ConnectionTypeName; diff --git a/src/client.ts b/src/client.ts index 8036a11..bab42dc 100755 --- a/src/client.ts +++ b/src/client.ts @@ -1,6 +1,6 @@ -import { IBLEConnection } from "./adapters/iBleConnection.js"; -import { IHTTPConnection } from "./adapters/iHttpConnection.js"; -import { ISerialConnection } from "./adapters/iSerialConnection.js"; +import { BleConnection } from "./adapters/bleConnection.js"; +import { HttpConnection } from "./adapters/httpConnection.js"; +import { SerialConnection } from "./adapters/serialConnection.js"; import { Types } from "./index.js"; /** @@ -19,26 +19,26 @@ export class Client { /** * Creates a new Bluetooth Low Enery connection interface */ - public createBLEConnection(configId?: number): IBLEConnection { - const iBLEConnection = new IBLEConnection(configId); - this.deviceInterfaces.push(iBLEConnection); - return iBLEConnection; + public createBleConnection(configId?: number): BleConnection { + const bleConnection = new BleConnection(configId); + this.deviceInterfaces.push(bleConnection); + return bleConnection; } /** * Creates a new HTTP(S) connection interface */ - public createHTTPConnection(configId?: number): IHTTPConnection { - const iHTTPConnection = new IHTTPConnection(configId); - this.deviceInterfaces.push(iHTTPConnection); - return iHTTPConnection; + public createHttpConnection(configId?: number): HttpConnection { + const httpConnection = new HttpConnection(configId); + this.deviceInterfaces.push(httpConnection); + return httpConnection; } /** * Creates a new Serial connection interface */ - public createSerialConnection(configId?: number): ISerialConnection { - const iSerialConnection = new ISerialConnection(configId); + public createSerialConnection(configId?: number): SerialConnection { + const iSerialConnection = new SerialConnection(configId); this.deviceInterfaces.push(iSerialConnection); return iSerialConnection; } diff --git a/src/constants.ts b/src/constants.ts index 8397ee9..bf9cfb1 100644 --- a/src/constants.ts +++ b/src/constants.ts @@ -1,17 +1,17 @@ /** Bluetooth Low Energy ToRadio characteristic */ -export const toRadioUUID = "f75c76d2-129e-4dad-a1dd-7866124401e7"; +export const ToRadioUuid = "f75c76d2-129e-4dad-a1dd-7866124401e7"; /** Bluetooth Low Energy FromRadio characteristic */ -export const fromRadioUUID = "2c55e69e-4993-11ed-b878-0242ac120002"; +export const FromRadioUuid = "2c55e69e-4993-11ed-b878-0242ac120002"; /** * Bluetooth Low Energy FromNum characteristic, provides BLE notification on new * FromRadio message and a message counter */ -export const fromNumUUID = "ed9da18c-a800-4f66-a670-aa7547e34453"; +export const FromNumUuid = "ed9da18c-a800-4f66-a670-aa7547e34453"; /** Bluetooth Service characteristic, used to identify Meshtastic devices */ -export const serviceUUID = "6ba1b218-15a8-461f-9fa8-5dcae273eafd"; +export const ServiceUuid = "6ba1b218-15a8-461f-9fa8-5dcae273eafd"; /** Broadcast destination number */ export const broadcastNum = 0xffffffff; diff --git a/src/index.ts b/src/index.ts index ab6eac5..a8e9956 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,18 +1,18 @@ -import { IBLEConnection } from "./adapters/iBleConnection.js"; -import { IHTTPConnection } from "./adapters/iHttpConnection.js"; -import { ISerialConnection } from "./adapters/iSerialConnection.js"; +import { BleConnection } from "./adapters/bleConnection.js"; +import { HttpConnection } from "./adapters/httpConnection.js"; +import { SerialConnection } from "./adapters/serialConnection.js"; import { Client } from "./client.js"; import * as Constants from "./constants.js"; -import { IMeshDevice } from "./iMeshDevice.js"; +import { MeshDevice } from "./meshDevice.js"; import * as Protobuf from "./protobufs.js"; import * as Types from "./types.js"; export { Client, - IMeshDevice, - IBLEConnection, - IHTTPConnection, - ISerialConnection, + MeshDevice as IMeshDevice, + BleConnection as IBLEConnection, + HttpConnection as IHTTPConnection, + SerialConnection as ISerialConnection, Types, Constants, Protobuf, diff --git a/src/iMeshDevice.ts b/src/meshDevice.ts similarity index 98% rename from src/iMeshDevice.ts rename to src/meshDevice.ts index b48332e..fc4e672 100755 --- a/src/iMeshDevice.ts +++ b/src/meshDevice.ts @@ -4,10 +4,10 @@ import { broadcastNum, minFwVer } from "./constants.js"; import { Protobuf, Types } from "./index.js"; import { EventSystem } from "./utils/eventSystem.js"; import { Queue } from "./utils/queue.js"; -import { XModem } from "./utils/xmodem.js"; +import { Xmodem } from "./utils/xmodem.js"; /** Base class for connection methods to extend */ -export abstract class IMeshDevice { +export abstract class MeshDevice { /** Abstract property that states the connection type */ protected abstract connType: Types.ConnectionTypeName; @@ -39,7 +39,7 @@ export abstract class IMeshDevice { public events: EventSystem; - public XModem: XModem; + public XModem: Xmodem; constructor(configId?: number) { this.log = new Logger({ @@ -55,7 +55,7 @@ export abstract class IMeshDevice { this.configId = configId ?? this.generateRandId(); this.queue = new Queue(); this.events = new EventSystem(); - this.XModem = new XModem(this.sendRaw.bind(this)); //TODO: try wihtout bind + this.XModem = new Xmodem(this.sendRaw.bind(this)); //TODO: try wihtout bind this.events.onDeviceStatus.subscribe((status) => { this.deviceStatus = status; @@ -212,18 +212,17 @@ export abstract class IMeshDevice { ): Promise { if (toRadio.length > 512) { throw new Error("Message longer than 512 bytes, it will not be sent!"); - } else { - this.queue.push({ - id, - data: toRadio, - }); + } + this.queue.push({ + id, + data: toRadio, + }); - await this.queue.processQueue(async (data) => { - await this.writeToRadio(data); - }); + await this.queue.processQueue(async (data) => { + await this.writeToRadio(data); + }); - return this.queue.wait(id); - } + return this.queue.wait(id); } /** @@ -682,7 +681,7 @@ export abstract class IMeshDevice { throw new Error("Cannot generate CSPRN"); } - return Math.floor(seed[0] * Math.pow(2, -32) * 1e9); + return Math.floor(seed[0] * 2 ** -32 * 1e9); } /** diff --git a/src/types.ts b/src/types.ts index 45ddc69..b3ac792 100644 --- a/src/types.ts +++ b/src/types.ts @@ -5,7 +5,7 @@ import type { Protobuf, } from "./index.js"; -export interface IQueueItem { +export interface QueueItem { id: number; data: Uint8Array; sent: boolean; @@ -24,11 +24,11 @@ export enum DeviceStatusEnum { } export type ConnectionParameters = - | HTTPConnectionParameters - | BLEConnectionParameters + | HttpConnectionParameters + | BleConnectionParameters | SerialConnectionParameters; -export interface HTTPConnectionParameters { +export interface HttpConnectionParameters { /** Address The IP Address/Domain to connect to, without protocol */ address: string; /** @@ -45,7 +45,7 @@ export interface HTTPConnectionParameters { fetchInterval: number; } -export interface BLEConnectionParameters { +export interface BleConnectionParameters { /** Optional filter options for the web bluetooth api requestDevice() method */ deviceFilter?: RequestDeviceOptions; /** Connect directly to a Bluetooth deivce, obtained from `getDevices()` */ diff --git a/src/utils/queue.ts b/src/utils/queue.ts index 5785cba..95c6d3f 100644 --- a/src/utils/queue.ts +++ b/src/utils/queue.ts @@ -1,9 +1,9 @@ import { Protobuf } from "../index.js"; -import { IQueueItem, PacketError } from "../types.js"; +import { QueueItem, PacketError } from "../types.js"; import { SubEvent } from "sub-events"; export class Queue { - private queue: IQueueItem[] = []; + private queue: QueueItem[] = []; private lock = false; private ackNotifier = new SubEvent(); private errorNotifier = new SubEvent(); @@ -13,7 +13,7 @@ export class Queue { this.timeout = 60000; } - public getState(): IQueueItem[] { + public getState(): QueueItem[] { return this.queue; } @@ -21,8 +21,8 @@ export class Queue { this.queue = []; } - public push(item: Omit): void { - const queueItem: IQueueItem = { + public push(item: Omit): void { + const queueItem: QueueItem = { ...item, sent: false, added: new Date(), diff --git a/src/utils/xmodem.ts b/src/utils/xmodem.ts index fb03535..0999b68 100644 --- a/src/utils/xmodem.ts +++ b/src/utils/xmodem.ts @@ -2,16 +2,16 @@ import { Protobuf } from "../index.js"; import crc16ccitt from "crc/calculators/crc16ccitt"; //if counter > 35 then reset counter/clear/error/reject promise -type XModemProps = (toRadio: Uint8Array, id?: number) => Promise; +type XmodemProps = (toRadio: Uint8Array, id?: number) => Promise; -export class XModem { - private sendRaw: XModemProps; +export class Xmodem { + private sendRaw: XmodemProps; private rxBuffer: Uint8Array[]; private txBuffer: Uint8Array[]; private textEncoder: TextEncoder; private counter: number; - constructor(sendRaw: XModemProps) { + constructor(sendRaw: XmodemProps) { this.sendRaw = sendRaw; this.rxBuffer = []; this.txBuffer = [];