From f18163206fcbe104bdd8c81c5a358a5f2177f890 Mon Sep 17 00:00:00 2001 From: Patrick Pircher Date: Fri, 28 Feb 2025 17:02:11 +0100 Subject: [PATCH] upgrade to esm --- .eslintrc.js | 20 - bin/cli.js | 8 +- eslint.config.mjs | 50 ++ index.js | 2 +- package.json | 24 +- pnpm-lock.yaml | 864 +++++++++++++++++--------- src/__mocks__/changelog.ts | 4 +- src/__mocks__/github-api.ts | 2 +- src/changelog.ts | 34 +- src/cli.ts | 26 +- src/configuration-error.spec.ts | 2 +- src/configuration-error.ts | 3 +- src/configuration.spec.ts | 12 +- src/configuration.ts | 53 +- src/fetch.ts | 2 +- src/find-pull-request-id.spec.ts | 2 +- src/functional/markdown-empty.spec.js | 2 - src/functional/markdown-full.spec.js | 2 - src/git.spec.ts | 2 +- src/git.ts | 4 +- src/github-api.spec.ts | 2 +- src/github-api.ts | 7 +- src/index.ts | 4 +- src/interfaces.ts | 2 +- src/markdown-renderer.spec.ts | 4 +- src/markdown-renderer.ts | 8 +- src/progress-bar.ts | 5 +- tsconfig.json | 21 +- 28 files changed, 732 insertions(+), 439 deletions(-) delete mode 100644 .eslintrc.js create mode 100644 eslint.config.mjs diff --git a/.eslintrc.js b/.eslintrc.js deleted file mode 100644 index 0f8617d..0000000 --- a/.eslintrc.js +++ /dev/null @@ -1,20 +0,0 @@ -module.exports = { - env: { - es6: true, - node: true, - }, - extends: ["plugin:@typescript-eslint/eslint-recommended", "plugin:prettier/recommended"], - globals: { - Atomics: "readonly", - SharedArrayBuffer: "readonly", - }, - parser: "@typescript-eslint/parser", - parserOptions: { - ecmaVersion: 2018, - sourceType: "module", - }, - plugins: ["@typescript-eslint"], - rules: { - "prefer-const": "off", - }, -}; diff --git a/bin/cli.js b/bin/cli.js index e4847ad..3e20db9 100755 --- a/bin/cli.js +++ b/bin/cli.js @@ -2,6 +2,10 @@ "use strict"; -var cli = require("../lib/cli"); +async function run() { + var cli = await import("../lib/cli.js"); -cli.run(); + await cli.run(); +} + +run(); diff --git a/eslint.config.mjs b/eslint.config.mjs new file mode 100644 index 0000000..5df691d --- /dev/null +++ b/eslint.config.mjs @@ -0,0 +1,50 @@ +import globals from 'globals'; +import nodePlugin from 'eslint-plugin-n'; +import eslint from '@eslint/js'; +import tseslint from 'typescript-eslint'; +import eslintConfigPrettier from 'eslint-config-prettier'; + +export default tseslint.config( + { + ignores: ['dist/', 'node_modules/'], + }, + nodePlugin.configs['flat/recommended-module'], + eslint.configs.recommended, + tseslint.configs.recommended, + { + languageOptions: { + globals: { + ...globals.node, + }, + ecmaVersion: 'latest', + sourceType: 'module', + }, + + rules: { + 'n/no-process-exit': 0, + '@typescript-eslint/no-explicit-any': 0, + '@typescript-eslint/no-unused-expressions': 0, + "n/no-missing-import": ["error", { + "tryExtensions": [".js", ".ts", ".json", ".node"] + }], + "prefer-const": "off", + + 'n/hashbang': [ + 'error', + { + convertPath: { + 'src/*.ts': ['^src/(.+).ts$', 'dist/$1.js'], + }, + }, + ], + }, + }, + { + files: ['src/*.test.ts', 'eslint.config.mjs'], + + rules: { + 'n/no-unpublished-import': 0, + }, + }, + eslintConfigPrettier, +); diff --git a/index.js b/index.js index bf63049..735d006 100644 --- a/index.js +++ b/index.js @@ -1 +1 @@ -module.exports = require("./lib"); +export * from "./lib/index.js"; diff --git a/package.json b/package.json index 1742086..08c6f80 100644 --- a/package.json +++ b/package.json @@ -17,6 +17,7 @@ "license": "MIT", "author": "Bo Borgerson ", "main": "index.js", + "type": "module", "bin": { "github-changelog": "bin/cli.js" }, @@ -25,8 +26,10 @@ "changelog": "node ./bin/cli.js", "clean": "rimraf lib", "fix": "pnpm lint --fix", - "lint": "eslint src --ext ts --format stylish", - "prepack": "pnpm build", + "lint": "pnpm run /lint:.*/", + "lint:js": "eslint src --ext ts --format stylish", + "lint:types": "tsc --noEmit", + "prepare": "pnpm build", "prettier": "prettier --write 'src/**/*.ts'", "test": "vitest", "test-ci": "pnpm build && pnpm test", @@ -51,17 +54,24 @@ "yargs": "^17.1.0" }, "devDependencies": { + "@eslint/js": "^9.21.0", + "@types/fs-extra": "^11.0.4", + "@types/hosted-git-info": "^3.0.5", + "@types/make-fetch-happen": "^10.0.4", "@types/node": "22.10.10", - "@typescript-eslint/eslint-plugin": "5.62.0", - "@typescript-eslint/parser": "5.62.0", - "eslint": "8.55.0", + "@types/progress": "^2.0.7", + "@types/yargs": "^17.0.33", + "eslint": "^9.21.0", "eslint-config-prettier": "9.1.0", + "eslint-plugin-n": "^17.15.1", "eslint-plugin-prettier": "4.2.1", "fs-extra": "10.1.0", - "prettier": "2.8.8", + "globals": "^16.0.0", + "prettier": "^3.5.0", "release-plan": "^0.11.0", "rimraf": "3.0.2", - "typescript": "5.0.4", + "typescript": "^5.7.3", + "typescript-eslint": "^8.25.0", "vitest": "^3.0.4" }, "packageManager": "pnpm@10.4.1+sha512.c753b6c3ad7afa13af388fa6d808035a008e30ea9993f58c6663e2bc5ff21679aa834db094987129aa4d488b86df57f7b634981b2f827cdcacc698cc0cfb88af", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 90c9506..e0c63f4 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -36,30 +36,48 @@ importers: specifier: ^17.1.0 version: 17.7.2 devDependencies: + '@eslint/js': + specifier: ^9.21.0 + version: 9.21.0 + '@types/fs-extra': + specifier: ^11.0.4 + version: 11.0.4 + '@types/hosted-git-info': + specifier: ^3.0.5 + version: 3.0.5 + '@types/make-fetch-happen': + specifier: ^10.0.4 + version: 10.0.4 '@types/node': specifier: 22.10.10 version: 22.10.10 - '@typescript-eslint/eslint-plugin': - specifier: 5.62.0 - version: 5.62.0(@typescript-eslint/parser@5.62.0(eslint@8.55.0)(typescript@5.0.4))(eslint@8.55.0)(typescript@5.0.4) - '@typescript-eslint/parser': - specifier: 5.62.0 - version: 5.62.0(eslint@8.55.0)(typescript@5.0.4) + '@types/progress': + specifier: ^2.0.7 + version: 2.0.7 + '@types/yargs': + specifier: ^17.0.33 + version: 17.0.33 eslint: - specifier: 8.55.0 - version: 8.55.0 + specifier: ^9.21.0 + version: 9.21.0 eslint-config-prettier: specifier: 9.1.0 - version: 9.1.0(eslint@8.55.0) + version: 9.1.0(eslint@9.21.0) + eslint-plugin-n: + specifier: ^17.15.1 + version: 17.15.1(eslint@9.21.0) eslint-plugin-prettier: specifier: 4.2.1 - version: 4.2.1(eslint-config-prettier@9.1.0(eslint@8.55.0))(eslint@8.55.0)(prettier@2.8.8) + version: 4.2.1(eslint-config-prettier@9.1.0(eslint@9.21.0))(eslint@9.21.0)(prettier@3.5.2) fs-extra: specifier: 10.1.0 version: 10.1.0 + globals: + specifier: ^16.0.0 + version: 16.0.0 prettier: - specifier: 2.8.8 - version: 2.8.8 + specifier: ^3.5.0 + version: 3.5.2 release-plan: specifier: ^0.11.0 version: 0.11.0(encoding@0.1.13) @@ -67,8 +85,11 @@ importers: specifier: 3.0.2 version: 3.0.2 typescript: - specifier: 5.0.4 - version: 5.0.4 + specifier: ^5.7.3 + version: 5.7.3 + typescript-eslint: + specifier: ^8.25.0 + version: 8.25.0(eslint@9.21.0)(typescript@5.7.3) vitest: specifier: ^3.0.4 version: 3.0.6(@types/node@22.10.10) @@ -235,29 +256,52 @@ packages: resolution: {integrity: sha512-CCZCDJuduB9OUkFkY2IgppNZMi2lBQgD2qzwXkEia16cge2pijY/aXi96CJMquDMn3nJdlPV1A5KrJEXwfLNzQ==} engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} - '@eslint/eslintrc@2.1.4': - resolution: {integrity: sha512-269Z39MS6wVJtsoUl10L60WdkhJVdPG24Q4eZTH3nnF6lpvSShEK3wQjDX9JRWAUPvPh7COouPpU9IrqaZFvtQ==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + '@eslint/config-array@0.19.2': + resolution: {integrity: sha512-GNKqxfHG2ySmJOBSHg7LxeUx4xpuCoFjacmlCoYWEbaPXLwvfIjixRI12xCQZeULksQb23uiA8F40w5TojpV7w==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@eslint/js@8.55.0': - resolution: {integrity: sha512-qQfo2mxH5yVom1kacMtZZJFVdW+E70mqHMJvVg6WTLo+VBuQJ4TojZlfWBjK0ve5BdEeNAVxOsl/nvNMpJOaJA==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + '@eslint/core@0.12.0': + resolution: {integrity: sha512-cmrR6pytBuSMTaBweKoGMwu3EiHiEC+DoyupPmlZ0HxBJBtIxwe+j/E4XPIKNx+Q74c8lXKPwYawBf5glsTkHg==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + + '@eslint/eslintrc@3.3.0': + resolution: {integrity: sha512-yaVPAiNAalnCZedKLdR21GOGILMLKPyqSLWaAjQFvYA2i/ciDi8ArYVr69Anohb6cH2Ukhqti4aFnYyPm8wdwQ==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + + '@eslint/js@9.21.0': + resolution: {integrity: sha512-BqStZ3HX8Yz6LvsF5ByXYrtigrV5AXADWLAGc7PH/1SxOb7/FIYYMszZZWiUou/GB9P2lXWk2SV4d+Z8h0nknw==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + + '@eslint/object-schema@2.1.6': + resolution: {integrity: sha512-RBMg5FRL0I0gs51M/guSAj5/e14VQ4tpZnQNWwuDT66P14I43ItmPfIZRhO9fUVIPOAQXU47atlywZ/czoqFPA==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + + '@eslint/plugin-kit@0.2.7': + resolution: {integrity: sha512-JubJ5B2pJ4k4yGxaNLdbjrnk9d/iDz6/q8wOilpIowd6PJPgaxCuHBnBszq7Ce2TyMrywm5r4PnKm6V3iiZF+g==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} '@gar/promisify@1.1.3': resolution: {integrity: sha512-k2Ty1JcVojjJFwrg/ThKi2ujJ7XNLYaFGNB/bWT9wGR+oSMJHMa5w+CUq6p/pVrKeNNgA7pCqEcjSnHVoqJQFw==} - '@humanwhocodes/config-array@0.11.14': - resolution: {integrity: sha512-3T8LkOmg45BV5FICb15QQMsyUSWrQ8AygVfC7ZG32zOalnqrilm018ZVCw0eapXux8FtA33q8PSRSstjee3jSg==} - engines: {node: '>=10.10.0'} - deprecated: Use @eslint/config-array instead + '@humanfs/core@0.19.1': + resolution: {integrity: sha512-5DyQ4+1JEUzejeK1JGICcideyfUbGixgS9jNgex5nqkW+cY7WZhxBigmieN5Qnw9ZosSNVC9KQKyb+GUaGyKUA==} + engines: {node: '>=18.18.0'} + + '@humanfs/node@0.16.6': + resolution: {integrity: sha512-YuI2ZHQL78Q5HbhDiBA1X4LmYdXCKCMQIfw0pw7piHJwyREFebJUvrQN4cMssyES6x+vfUbx1CIpaQUKYdQZOw==} + engines: {node: '>=18.18.0'} '@humanwhocodes/module-importer@1.0.1': resolution: {integrity: sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==} engines: {node: '>=12.22'} - '@humanwhocodes/object-schema@2.0.3': - resolution: {integrity: sha512-93zYdMES/c1D69yZiKDBj0V24vqNzB/koF26KPaagAfd3P/4gUlh3Dys5ogAK+Exi9QyzlD8x/08Zt7wIKcDcA==} - deprecated: Use @eslint/object-schema instead + '@humanwhocodes/retry@0.3.1': + resolution: {integrity: sha512-JBxkERygn7Bv/GbN5Rv8Ul6LVknS+5Bp6RgDC/O8gEBU/yeH5Ui5C/OlWrTb6qct7LjjfT6Re2NxB0ln0yYybA==} + engines: {node: '>=18.18'} + + '@humanwhocodes/retry@0.4.2': + resolution: {integrity: sha512-xeO57FpIu4p1Ri3Jq/EXq4ClRm86dVF2z/+kvFnyqVYRavTZmaFaUBbWCOuuTh0o/g7DSsk6kc2vrS4Vl5oPOQ==} + engines: {node: '>=18.18'} '@isaacs/cliui@8.0.2': resolution: {integrity: sha512-O8jcjabXaleOG9DQ0+ARXWZBTfnP4WNAqzuiJK7ll44AmxGKv/J2M4TPjxjY3znBCfvBXFzucm1twdyFybFqEA==} @@ -485,75 +529,88 @@ packages: '@types/estree@1.0.6': resolution: {integrity: sha512-AYnb1nQyY49te+VRAVgmzfcgjYS91mY5P0TKUDCLEM+gNnA+3T6rWITXRLYCpahpqSQbN5cE+gHpnPyXjHWxcw==} + '@types/fs-extra@11.0.4': + resolution: {integrity: sha512-yTbItCNreRooED33qjunPthRcSjERP1r4MqCZc7wv0u2sUkzTFp45tgUfS5+r7FrZPdmCCNflLhVSP/o+SemsQ==} + + '@types/hosted-git-info@3.0.5': + resolution: {integrity: sha512-Dmngh7U003cOHPhKGyA7LWqrnvcTyILNgNPmNCxlx7j8MIi54iBliiT8XqVLIQ3GchoOjVAyBzNJVyuaJjqokg==} + '@types/json-schema@7.0.15': resolution: {integrity: sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==} + '@types/jsonfile@6.1.4': + resolution: {integrity: sha512-D5qGUYwjvnNNextdU59/+fI+spnwtTFmyQP0h+PfIOSkNfpU6AOICUOkm4i0OnSk+NyjdPJrxCDro0sJsWlRpQ==} + + '@types/make-fetch-happen@10.0.4': + resolution: {integrity: sha512-jKzweQaEMMAi55ehvR1z0JF6aSVQm/h1BXBhPLOJriaeQBctjw5YbpIGs7zAx9dN0Sa2OO5bcXwCkrlgenoPEA==} + + '@types/node-fetch@2.6.12': + resolution: {integrity: sha512-8nneRWKCg3rMtF69nLQJnOYUcbafYeFSjqkw3jCRLsqkWFlHaoQrr5mXmofFGOx3DKn7UfmBMyov8ySvLRVldA==} + '@types/node@22.10.10': resolution: {integrity: sha512-X47y/mPNzxviAGY5TcYPtYL8JsY3kAq2n8fMmKoRCxq/c4v4pyGNCzM2R6+M5/umG4ZfHuT+sgqDYqWc9rJ6ww==} - '@types/semver@7.5.8': - resolution: {integrity: sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==} + '@types/progress@2.0.7': + resolution: {integrity: sha512-iadjw02vte8qWx7U0YM++EybBha2CQLPGu9iJ97whVgJUT5Zq9MjAPYUnbfRI2Kpehimf1QjFJYxD0t8nqzu5w==} - '@typescript-eslint/eslint-plugin@5.62.0': - resolution: {integrity: sha512-TiZzBSJja/LbhNPvk6yc0JrX9XqhQ0hdh6M2svYfsHGejaKFIAGd9MQ+ERIMzLGlN/kZoYIgdxFV0PuljTKXag==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + '@types/retry@0.12.5': + resolution: {integrity: sha512-3xSjTp3v03X/lSQLkczaN9UIEwJMoMCA1+Nb5HfbJEQWogdeQIyVtTvxPXDQjZ5zws8rFQfVfRdz03ARihPJgw==} + + '@types/ssri@7.1.5': + resolution: {integrity: sha512-odD/56S3B51liILSk5aXJlnYt99S6Rt9EFDDqGtJM26rKHApHcwyU/UoYHrzKkdkHMAIquGWCuHtQTbes+FRQw==} + + '@types/yargs-parser@21.0.3': + resolution: {integrity: sha512-I4q9QU9MQv4oEOz4tAHJtNz1cwuLxn2F3xcc2iV5WdqLPpUnj30aUuxt1mAxYTG+oe8CZMV/+6rU4S4gRDzqtQ==} + + '@types/yargs@17.0.33': + resolution: {integrity: sha512-WpxBCKWPLr4xSsHgz511rFJAM+wS28w2zEO1QDNY5zM/S8ok70NNfztH0xwhqKyaK0OHCbN98LDAZuy1ctxDkA==} + + '@typescript-eslint/eslint-plugin@8.25.0': + resolution: {integrity: sha512-VM7bpzAe7JO/BFf40pIT1lJqS/z1F8OaSsUB3rpFJucQA4cOSuH2RVVVkFULN+En0Djgr29/jb4EQnedUo95KA==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: - '@typescript-eslint/parser': ^5.0.0 - eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 - typescript: '*' - peerDependenciesMeta: - typescript: - optional: true + '@typescript-eslint/parser': ^8.0.0 || ^8.0.0-alpha.0 + eslint: ^8.57.0 || ^9.0.0 + typescript: '>=4.8.4 <5.8.0' - '@typescript-eslint/parser@5.62.0': - resolution: {integrity: sha512-VlJEV0fOQ7BExOsHYAGrgbEiZoi8D+Bl2+f6V2RrXerRSylnp+ZBHmPvaIa8cz0Ajx7WO7Z5RqfgYg7ED1nRhA==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + '@typescript-eslint/parser@8.25.0': + resolution: {integrity: sha512-4gbs64bnbSzu4FpgMiQ1A+D+urxkoJk/kqlDJ2W//5SygaEiAP2B4GoS7TEdxgwol2el03gckFV9lJ4QOMiiHg==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: - eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 - typescript: '*' - peerDependenciesMeta: - typescript: - optional: true + eslint: ^8.57.0 || ^9.0.0 + typescript: '>=4.8.4 <5.8.0' - '@typescript-eslint/scope-manager@5.62.0': - resolution: {integrity: sha512-VXuvVvZeQCQb5Zgf4HAxc04q5j+WrNAtNh9OwCsCgpKqESMTu3tF/jhZ3xG6T4NZwWl65Bg8KuS2uEvhSfLl0w==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + '@typescript-eslint/scope-manager@8.25.0': + resolution: {integrity: sha512-6PPeiKIGbgStEyt4NNXa2ru5pMzQ8OYKO1hX1z53HMomrmiSB+R5FmChgQAP1ro8jMtNawz+TRQo/cSXrauTpg==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/type-utils@5.62.0': - resolution: {integrity: sha512-xsSQreu+VnfbqQpW5vnCJdq1Z3Q0U31qiWmRhr98ONQmcp/yhiPJFPq8MXiJVLiksmOKSjIldZzkebzHuCGzew==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + '@typescript-eslint/type-utils@8.25.0': + resolution: {integrity: sha512-d77dHgHWnxmXOPJuDWO4FDWADmGQkN5+tt6SFRZz/RtCWl4pHgFl3+WdYCn16+3teG09DY6XtEpf3gGD0a186g==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: - eslint: '*' - typescript: '*' - peerDependenciesMeta: - typescript: - optional: true + eslint: ^8.57.0 || ^9.0.0 + typescript: '>=4.8.4 <5.8.0' - '@typescript-eslint/types@5.62.0': - resolution: {integrity: sha512-87NVngcbVXUahrRTqIK27gD2t5Cu1yuCXxbLcFtCzZGlfyVWWh8mLHkoxzjsB6DDNnvdL+fW8MiwPEJyGJQDgQ==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + '@typescript-eslint/types@8.25.0': + resolution: {integrity: sha512-+vUe0Zb4tkNgznQwicsvLUJgZIRs6ITeWSCclX1q85pR1iOiaj+4uZJIUp//Z27QWu5Cseiw3O3AR8hVpax7Aw==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/typescript-estree@5.62.0': - resolution: {integrity: sha512-CmcQ6uY7b9y694lKdRB8FEel7JbU/40iSAPomu++SjLMntB+2Leay2LO6i8VnJk58MtE9/nQSFIH6jpyRWyYzA==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + '@typescript-eslint/typescript-estree@8.25.0': + resolution: {integrity: sha512-ZPaiAKEZ6Blt/TPAx5Ot0EIB/yGtLI2EsGoY6F7XKklfMxYQyvtL+gT/UCqkMzO0BVFHLDlzvFqQzurYahxv9Q==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: - typescript: '*' - peerDependenciesMeta: - typescript: - optional: true + typescript: '>=4.8.4 <5.8.0' - '@typescript-eslint/utils@5.62.0': - resolution: {integrity: sha512-n8oxjeb5aIbPFEtmQxQYOLI0i9n5ySBEY/ZEHHZqKQSFnxio1rv6dthascc9dLuwrL0RC5mPCxB7vnAVGAYWAQ==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + '@typescript-eslint/utils@8.25.0': + resolution: {integrity: sha512-syqRbrEv0J1wywiLsK60XzHnQe/kRViI3zwFALrNEgnntn1l24Ra2KvOAWwWbWZ1lBZxZljPDGOq967dsl6fkA==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: - eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 - - '@typescript-eslint/visitor-keys@5.62.0': - resolution: {integrity: sha512-07ny+LHRzQXepkGg6w0mFY41fVUNBrL2Roj/++7V1txKugfjm/Ci/qSND03r2RhlJhJYMcTn9AhhSSqQp0Ysyw==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + eslint: ^8.57.0 || ^9.0.0 + typescript: '>=4.8.4 <5.8.0' - '@ungap/structured-clone@1.3.0': - resolution: {integrity: sha512-WmoN8qaIAo7WTYWbAZuG8PYEhn5fkz7dZrqTBZ7dtt//lL2Gwms1IcnQ5yHqjDfX8Ft5j4YzDM23f87zBfDe9g==} + '@typescript-eslint/visitor-keys@8.25.0': + resolution: {integrity: sha512-kCYXKAum9CecGVHGij7muybDfTS2sD3t0L4bJsEZLkyrXUImiCTq1M3LG2SRtOhiHFwMR9wAFplpT6XHYjTkwQ==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} '@vitest/expect@3.0.6': resolution: {integrity: sha512-zBduHf/ja7/QRX4HdP1DSq5XrPgdN+jzLOwaTq/0qZjYfgETNFCKf9nOAp2j3hmom3oTbczuUzrzg9Hafh7hNg==} @@ -631,10 +688,6 @@ packages: argparse@2.0.1: resolution: {integrity: sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==} - array-union@2.1.0: - resolution: {integrity: sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==} - engines: {node: '>=8'} - assert-never@1.4.0: resolution: {integrity: sha512-5oJg84os6NMQNl27T9LnZkvvqzvAnHu03ShCnoj6bsJwS7L8AO4lf+C/XjK/nvzEqQB744moC6V128RucQd1jA==} @@ -642,6 +695,9 @@ packages: resolution: {integrity: sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA==} engines: {node: '>=12'} + asynckit@0.4.0: + resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==} + balanced-match@1.0.2: resolution: {integrity: sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==} @@ -666,6 +722,10 @@ packages: resolution: {integrity: sha512-VVdYzXEn+cnbXpFgWs5hTT7OScegHVmLhJIR8Ufqk3iFD6A6j5iSX1KuBTfNEv4tdJWE2PzA6IVFtcLC7fN9wQ==} engines: {node: '>= 10'} + call-bind-apply-helpers@1.0.2: + resolution: {integrity: sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==} + engines: {node: '>= 0.4'} + callsites@3.1.0: resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==} engines: {node: '>=6'} @@ -709,6 +769,10 @@ packages: color-name@1.1.4: resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} + combined-stream@1.0.8: + resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} + engines: {node: '>= 0.8'} + concat-map@0.0.1: resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==} @@ -739,16 +803,16 @@ packages: deep-is@0.1.4: resolution: {integrity: sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==} + delayed-stream@1.0.0: + resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==} + engines: {node: '>=0.4.0'} + deprecation@2.3.1: resolution: {integrity: sha512-xmHIy4F3scKVwMsQ4WnVaS8bHOx0DmVwRywosKhaILI0ywMDWPtBSku2HNxRvF7jtwDRsoEwYQSfbxj8b7RlJQ==} - dir-glob@3.0.1: - resolution: {integrity: sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==} - engines: {node: '>=8'} - - doctrine@3.0.0: - resolution: {integrity: sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==} - engines: {node: '>=6.0.0'} + dunder-proto@1.0.1: + resolution: {integrity: sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==} + engines: {node: '>= 0.4'} eastasianwidth@0.2.0: resolution: {integrity: sha512-I88TYZWc9XiYHRQ4/3c5rjjfgkjhLyW2luGIheGERbNQ6OY7yTybanSpDXZa8y7VUP9YmDcYa+eyq4ca7iLqWA==} @@ -765,12 +829,32 @@ packages: end-of-stream@1.4.4: resolution: {integrity: sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==} + enhanced-resolve@5.18.1: + resolution: {integrity: sha512-ZSW3ma5GkcQBIpwZTSRAI8N71Uuwgs93IezB7mf7R60tC8ZbJideoDNKjHn2O9KIlx6rkGTTEk1xUCK2E1Y2Yg==} + engines: {node: '>=10.13.0'} + err-code@2.0.3: resolution: {integrity: sha512-2bmlRpNKBxT/CRmPOlyISQpNj+qSeYvcym/uT0Jx2bMOlKLtSy1ZmLuVxSEKKyor/N5yhvp/ZiG1oE3DEYMSFA==} + es-define-property@1.0.1: + resolution: {integrity: sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==} + engines: {node: '>= 0.4'} + + es-errors@1.3.0: + resolution: {integrity: sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==} + engines: {node: '>= 0.4'} + es-module-lexer@1.6.0: resolution: {integrity: sha512-qqnD1yMU6tk/jnaMosogGySTZP8YtUgAffA9nMN+E/rjxcfRQ6IEk7IiozUjgxKoFHBGjTLnrHB/YC45r/59EQ==} + es-object-atoms@1.1.1: + resolution: {integrity: sha512-FGgH2h8zKNim9ljj7dankFPcICIK9Cp5bm+c2gQSYePhpaG5+esrLODihIorn+Pe6FGJzWhXQotPv73jTaldXA==} + engines: {node: '>= 0.4'} + + es-set-tostringtag@2.1.0: + resolution: {integrity: sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==} + engines: {node: '>= 0.4'} + esbuild@0.24.2: resolution: {integrity: sha512-+9egpBW8I3CD5XPe0n6BfT5fxLzxrlDzqydF3aviG+9ni1lDC/OvMHcxqEFV0+LANZG5R1bFMWfUrjVsdwxJvA==} engines: {node: '>=18'} @@ -784,12 +868,30 @@ packages: resolution: {integrity: sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==} engines: {node: '>=10'} + eslint-compat-utils@0.5.1: + resolution: {integrity: sha512-3z3vFexKIEnjHE3zCMRo6fn/e44U7T1khUjg+Hp0ZQMCigh28rALD0nPFBcGZuiLC5rLZa2ubQHDRln09JfU2Q==} + engines: {node: '>=12'} + peerDependencies: + eslint: '>=6.0.0' + eslint-config-prettier@9.1.0: resolution: {integrity: sha512-NSWl5BFQWEPi1j4TjVNItzYV7dZXZ+wP6I6ZhrBGpChQhZRUaElihE9uRRkcbRnNb76UMKDF3r+WTmNcGPKsqw==} hasBin: true peerDependencies: eslint: '>=7.0.0' + eslint-plugin-es-x@7.8.0: + resolution: {integrity: sha512-7Ds8+wAAoV3T+LAKeu39Y5BzXCrGKrcISfgKEqTS4BDN8SFEDQd0S43jiQ8vIa3wUKD07qitZdfzlenSi8/0qQ==} + engines: {node: ^14.18.0 || >=16.0.0} + peerDependencies: + eslint: '>=8' + + eslint-plugin-n@17.15.1: + resolution: {integrity: sha512-KFw7x02hZZkBdbZEFQduRGH4VkIH4MW97ClsbAM4Y4E6KguBJWGfWG1P4HEIpZk2bkoWf0bojpnjNAhYQP8beA==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + eslint: '>=8.23.0' + eslint-plugin-prettier@4.2.1: resolution: {integrity: sha512-f/0rXLXUt0oFYs8ra4w49wYZBG5GKZpAYsJSm6rnYL5uVDjd+zowwMwVZHnAjf4edNrKpCDYfXDgmRE/Ak7QyQ==} engines: {node: '>=12.0.0'} @@ -801,27 +903,31 @@ packages: eslint-config-prettier: optional: true - eslint-scope@5.1.1: - resolution: {integrity: sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==} - engines: {node: '>=8.0.0'} - - eslint-scope@7.2.2: - resolution: {integrity: sha512-dOt21O7lTMhDM+X9mB4GX+DZrZtCUJPL/wlcTqxyrx5IvO0IYtILdtrQGQp+8n5S0gwSVmOf9NQrjMOgfQZlIg==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + eslint-scope@8.2.0: + resolution: {integrity: sha512-PHlWUfG6lvPc3yvP5A4PNyBL1W8fkDUccmI21JUu/+GKZBoH/W5u6usENXUrWFRsyoW5ACUjFGgAFQp5gUlb/A==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} eslint-visitor-keys@3.4.3: resolution: {integrity: sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - eslint@8.55.0: - resolution: {integrity: sha512-iyUUAM0PCKj5QpwGfmCAG9XXbZCWsqP/eWAWrG/W0umvjuLRBECwSFdt+rCntju0xEH7teIABPwXpahftIaTdA==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} - deprecated: This version is no longer supported. Please see https://eslint.org/version-support for other options. + eslint-visitor-keys@4.2.0: + resolution: {integrity: sha512-UyLnSehNt62FFhSwjZlHmeokpRK59rcz29j+F1/aDgbkbRTk7wIc9XzdoasMUbRNKDM0qQt/+BJ4BrpFeABemw==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + + eslint@9.21.0: + resolution: {integrity: sha512-KjeihdFqTPhOMXTt7StsDxriV4n66ueuF/jfPNC3j/lduHwr/ijDwJMsF+wyMJethgiKi5wniIE243vi07d3pg==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} hasBin: true + peerDependencies: + jiti: '*' + peerDependenciesMeta: + jiti: + optional: true - espree@9.6.1: - resolution: {integrity: sha512-oruZaFkjorTpF32kDSI5/75ViwGeZginGGy2NoOSg3Q9bnwlnmDm4HLnkl0RE3n+njDXR037aY1+x58Z/zFdwQ==} - engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} + espree@10.3.0: + resolution: {integrity: sha512-0QYC8b24HWY8zjRnDTL6RiHfDbAWn63qb4LMj1Z4b076A4une81+z03Kg7l7mn/48PUTqoLptSXez8oknU8Clg==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} esquery@1.6.0: resolution: {integrity: sha512-ca9pw9fomFcKPvFLXhBKUK90ZvGibiGOvRJNbjljY7s7uq/5YO4BOzcYtJqExdx99rF6aAcnRxHmcUHcz6sQsg==} @@ -831,10 +937,6 @@ packages: resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==} engines: {node: '>=4.0'} - estraverse@4.3.0: - resolution: {integrity: sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==} - engines: {node: '>=4.0'} - estraverse@5.3.0: resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==} engines: {node: '>=4.0'} @@ -877,9 +979,9 @@ packages: fastq@1.19.0: resolution: {integrity: sha512-7SFSRCNjBQIZH/xZR3iy5iQYR8aGBE0h3VG6/cwlbrpdciNYBMotQav8c1XI3HjHH+NikUpP53nPdlZSdWmFzA==} - file-entry-cache@6.0.1: - resolution: {integrity: sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==} - engines: {node: ^10.12.0 || >=12.0.0} + file-entry-cache@8.0.0: + resolution: {integrity: sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==} + engines: {node: '>=16.0.0'} fill-range@7.1.1: resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==} @@ -889,9 +991,9 @@ packages: resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==} engines: {node: '>=10'} - flat-cache@3.2.0: - resolution: {integrity: sha512-CYcENa+FtcUKLmhhqyctpclsq7QF38pKjZHsGNiSQF5r4FtoKDWabFDl3hzaEQMvT1LHEysw5twgLvpYYb4vbw==} - engines: {node: ^10.12.0 || >=12.0.0} + flat-cache@4.0.1: + resolution: {integrity: sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==} + engines: {node: '>=16'} flatted@3.3.3: resolution: {integrity: sha512-GX+ysw4PBCz0PzosHDepZGANEuFCMLrnRTiEy9McGjmkCQYwRq4A/X786G/fjM/+OjsWSU1ZrY5qyARZmO/uwg==} @@ -900,6 +1002,10 @@ packages: resolution: {integrity: sha512-Ld2g8rrAyMYFXBhEqMz8ZAHBi4J4uS1i/CxGMDnjyFWddMXLVcDp051DZfu+t7+ab7Wv6SMqpWmyFIj5UbfFvg==} engines: {node: '>=14'} + form-data@4.0.2: + resolution: {integrity: sha512-hGfm/slu0ZabnNt4oaRZ6uREyfCj6P4fT/n6A1rGV+Z0VdGXjfOhVUpkn6qVQONHGIFwmveGXyDs75+nr6FM8w==} + engines: {node: '>= 6'} + fs-extra@10.1.0: resolution: {integrity: sha512-oRXApq54ETRj4eMiFzGnHWGy+zo5raudjuxN0b8H7s/RU2oW0Wvsx9O0ACRN/kRq9E8Vu/ReskGB5o3ji+FzHQ==} engines: {node: '>=12'} @@ -916,10 +1022,21 @@ packages: engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} os: [darwin] + function-bind@1.1.2: + resolution: {integrity: sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==} + get-caller-file@2.0.5: resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} engines: {node: 6.* || 8.* || >= 10.*} + get-intrinsic@1.3.0: + resolution: {integrity: sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==} + engines: {node: '>= 0.4'} + + get-proto@1.0.1: + resolution: {integrity: sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==} + engines: {node: '>= 0.4'} + get-stream@5.2.0: resolution: {integrity: sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==} engines: {node: '>=8'} @@ -928,6 +1045,9 @@ packages: resolution: {integrity: sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==} engines: {node: '>=10'} + get-tsconfig@4.10.0: + resolution: {integrity: sha512-kGzZ3LWWQcGIAmg6iWvXn0ei6WDtV26wzHRMwDSzmAbcXrTEXxHy6IehI6/4eT6VRKyMP1eF1VqwrVUmE/LR7A==} + github-changelog@1.2.0: resolution: {integrity: sha512-hLlDDWxGkN7QfjVCTohCravUaVoOIbOxTSeH/5K30luf5Z8s0JWrWzrz3ot1zlkSX4656vzw+iG8t1hmtiuq0g==} engines: {node: 12.* || 14.* || >= 16} @@ -949,13 +1069,21 @@ packages: resolution: {integrity: sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==} deprecated: Glob versions prior to v9 are no longer supported - globals@13.24.0: - resolution: {integrity: sha512-AhO5QUcj8llrbG09iWhPU2B204J1xnPeL8kQmVorSsy+Sjj1sk8gIyh6cUocGmH4L0UuhAJy+hJMRA4mgA4mFQ==} - engines: {node: '>=8'} + globals@14.0.0: + resolution: {integrity: sha512-oahGvuMGQlPw/ivIYBjVSrWAfWLBeku5tpPE2fOPLi+WHffIWbuh2tCjhyQhTBPMf5E9jDEH4FOmTYgYwbKwtQ==} + engines: {node: '>=18'} - globby@11.1.0: - resolution: {integrity: sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==} - engines: {node: '>=10'} + globals@15.15.0: + resolution: {integrity: sha512-7ACyT3wmyp3I61S4fG682L0VA2RGD9otkqGJIwNUMF1SWUombIIk+af1unuDYgMm082aHYwD+mzJvv9Iu8dsgg==} + engines: {node: '>=18'} + + globals@16.0.0: + resolution: {integrity: sha512-iInW14XItCXET01CQFqudPOWP2jYMl7T+QRQT+UNcR/iQncN/F0UNpgd76iFkBPgNQb4+X3LV9tLJYzwh+Gl3A==} + engines: {node: '>=18'} + + gopd@1.2.0: + resolution: {integrity: sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==} + engines: {node: '>= 0.4'} graceful-fs@4.2.10: resolution: {integrity: sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==} @@ -970,6 +1098,18 @@ packages: resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} engines: {node: '>=8'} + has-symbols@1.1.0: + resolution: {integrity: sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==} + engines: {node: '>= 0.4'} + + has-tostringtag@1.0.2: + resolution: {integrity: sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==} + engines: {node: '>= 0.4'} + + hasown@2.0.2: + resolution: {integrity: sha512-0hJU9SCPvmMzIBdZFqNPXWa6dqh7WdH0cII9y+CyS8rG3nL48Bclra9HmKhVVUHyPWNH5Y7xDwAB7bfgSjkUMQ==} + engines: {node: '>= 0.4'} + highlight.js@10.7.3: resolution: {integrity: sha512-tzcUFauisWKNHaRkN4Wjl/ZA07gENAjFl3J/c480dprkGTg5EQstgaNFqBfUqCq54kZRIEcreTsAgF/m2quD7A==} @@ -1063,10 +1203,6 @@ packages: resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} engines: {node: '>=0.12.0'} - is-path-inside@3.0.3: - resolution: {integrity: sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==} - engines: {node: '>=8'} - is-plain-object@5.0.0: resolution: {integrity: sha512-VRSzKkbMm5jMDoKLbltAkFQ5Qr7VDiTFGXxYFXXowVj387GeGNOCsOH6Msy00SGZ3Fp84b1Naa1psqgcCIEP5Q==} engines: {node: '>=0.10.0'} @@ -1150,6 +1286,10 @@ packages: resolution: {integrity: sha512-+zopwDy7DNknmwPQplem5lAZX/eCOzSvSNNcSKm5eVwTkOBzoktEfXsa9L23J/GIRhxRsaxzkPEhrJEpE2F4Gg==} engines: {node: '>= 10'} + math-intrinsics@1.1.0: + resolution: {integrity: sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==} + engines: {node: '>= 0.4'} + merge-stream@2.0.0: resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==} @@ -1161,6 +1301,14 @@ packages: resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==} engines: {node: '>=8.6'} + mime-db@1.52.0: + resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} + engines: {node: '>= 0.6'} + + mime-types@2.1.35: + resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==} + engines: {node: '>= 0.6'} + mimic-fn@2.1.0: resolution: {integrity: sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==} engines: {node: '>=6'} @@ -1227,9 +1375,6 @@ packages: engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} hasBin: true - natural-compare-lite@1.4.0: - resolution: {integrity: sha512-Tj+HTDSJJKaZnfiuw+iaF9skdPpTo2GtEly5JHnWV/hfv2Qj/9RKsGISQtLh2ox3l5EAGw487hnBee0sIJ6v2g==} - natural-compare@1.4.0: resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} @@ -1340,10 +1485,6 @@ packages: resolution: {integrity: sha512-Xa4Nw17FS9ApQFJ9umLiJS4orGjm7ZzwUrwamcGQuHSzDyth9boKDaycYdDcZDuqYATXw4HFXgaqWTctW/v1HA==} engines: {node: '>=16 || 14 >=14.18'} - path-type@4.0.0: - resolution: {integrity: sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==} - engines: {node: '>=8'} - pathe@2.0.3: resolution: {integrity: sha512-WUjGcAqP1gQacoQe+OBJsFA7Ld4DyXuUIjZ5cc75cLHvJ7dtNsTugphxIADwspS+AraAUePCKrSVtPLFj/F88w==} @@ -1370,9 +1511,9 @@ packages: resolution: {integrity: sha512-GbK2cP9nraSSUF9N2XwUwqfzlAFlMNYYl+ShE/V+H8a9uNl/oUqB1w2EL54Jh0OlyRSd8RfWYJ3coVS4TROP2w==} engines: {node: '>=6.0.0'} - prettier@2.8.8: - resolution: {integrity: sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==} - engines: {node: '>=10.13.0'} + prettier@3.5.2: + resolution: {integrity: sha512-lc6npv5PH7hVqozBR7lkBNOGXV9vMwROAPlumdBkX0wTbbzPu/U1hk5yL8p2pt4Xoc+2mkT8t/sow2YrV/M5qg==} + engines: {node: '>=14'} hasBin: true proc-log@4.2.0: @@ -1432,6 +1573,9 @@ packages: resolution: {integrity: sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==} engines: {node: '>=4'} + resolve-pkg-maps@1.0.0: + resolution: {integrity: sha512-seS2Tj26TBVOC2NIc2rOe2y2ZO7efxITtLZcGSOnHHNOQ7CkiUBfw0Iw2ck6xkIhPwLhKNLS8BO+hEpngQlqzw==} + retry@0.12.0: resolution: {integrity: sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==} engines: {node: '>= 4'} @@ -1479,10 +1623,6 @@ packages: resolution: {integrity: sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==} engines: {node: '>=14'} - slash@3.0.0: - resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} - engines: {node: '>=8'} - smart-buffer@4.2.0: resolution: {integrity: sha512-94hK0Hh8rPqQl2xXc3HsaBoOXKV20MToPkcXvwbISWLEs+64sBq5kFgn2kJDHb1Pry9yrP0dxrCI9RRci7RXKg==} engines: {node: '>= 6.0.0', npm: '>= 3.0.0'} @@ -1556,13 +1696,14 @@ packages: resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} engines: {node: '>=8'} + tapable@2.2.1: + resolution: {integrity: sha512-GNzQvQTOIP6RyTfE2Qxb8ZVlNmw0n88vp1szwWRimP02mnTsx3Wtn5qRdqY9w2XduFNUgvOwhNnQsjwCp+kqaQ==} + engines: {node: '>=6'} + tar@6.2.1: resolution: {integrity: sha512-DZ4yORTwrbTj/7MZYq2w+/ZFdI6OZ/f9SFHR+71gIVUZhOQPHzVCLpvRnPgyaMpfWxxk/4ONva3GQSyNIKRv6A==} engines: {node: '>=10'} - text-table@0.2.0: - resolution: {integrity: sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==} - thenify-all@1.6.0: resolution: {integrity: sha512-RNxQH/qI8/t3thXJDwcstUO4zeqo64+Uy/+sNVRBx4Xn2OX+OZ9oP+iJnNFqplFra2ZUVeKCSa2oVWi3T4uVmA==} engines: {node: '>=0.8'} @@ -1595,26 +1736,26 @@ packages: tr46@0.0.3: resolution: {integrity: sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==} - tslib@1.14.1: - resolution: {integrity: sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==} - - tsutils@3.21.0: - resolution: {integrity: sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA==} - engines: {node: '>= 6'} + ts-api-utils@2.0.1: + resolution: {integrity: sha512-dnlgjFSVetynI8nzgJ+qF62efpglpWRk8isUEWZGWlJYySCTD6aKvbUDu+zbPeDakk3bg5H4XpitHukgfL1m9w==} + engines: {node: '>=18.12'} peerDependencies: - 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' + typescript: '>=4.8.4' type-check@0.4.0: resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} engines: {node: '>= 0.8.0'} - type-fest@0.20.2: - resolution: {integrity: sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==} - engines: {node: '>=10'} + typescript-eslint@8.25.0: + resolution: {integrity: sha512-TxRdQQLH4g7JkoFlYG3caW5v1S6kEkz8rqt80iQJZUYPq1zD1Ra7HfQBJJ88ABRaMvHAXnwRvRB4V+6sQ9xN5Q==} + engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} + peerDependencies: + eslint: ^8.57.0 || ^9.0.0 + typescript: '>=4.8.4 <5.8.0' - typescript@5.0.4: - resolution: {integrity: sha512-cW9T5W9xY37cc+jfEnaUvX91foxtHkza3Nw3wkoF4sSlKn0MONdkdEndig/qPBWXNkmplh3NzayQzCiHM4/hqw==} - engines: {node: '>=12.20'} + typescript@5.7.3: + resolution: {integrity: sha512-84MVSjMEHP+FQRPy3pX9sTVV/INIex71s9TL2Gm5FG/WG1SqXeKyZ0k7/blY/4FdOzI12CBy1vGc4og/eus0fw==} + engines: {node: '>=14.17'} hasBin: true undici-types@6.20.0: @@ -1856,19 +1997,31 @@ snapshots: '@esbuild/win32-x64@0.24.2': optional: true - '@eslint-community/eslint-utils@4.4.1(eslint@8.55.0)': + '@eslint-community/eslint-utils@4.4.1(eslint@9.21.0)': dependencies: - eslint: 8.55.0 + eslint: 9.21.0 eslint-visitor-keys: 3.4.3 '@eslint-community/regexpp@4.12.1': {} - '@eslint/eslintrc@2.1.4': + '@eslint/config-array@0.19.2': + dependencies: + '@eslint/object-schema': 2.1.6 + debug: 4.4.0 + minimatch: 3.1.2 + transitivePeerDependencies: + - supports-color + + '@eslint/core@0.12.0': + dependencies: + '@types/json-schema': 7.0.15 + + '@eslint/eslintrc@3.3.0': dependencies: ajv: 6.12.6 debug: 4.4.0 - espree: 9.6.1 - globals: 13.24.0 + espree: 10.3.0 + globals: 14.0.0 ignore: 5.3.2 import-fresh: 3.3.1 js-yaml: 4.1.0 @@ -1877,21 +2030,29 @@ snapshots: transitivePeerDependencies: - supports-color - '@eslint/js@8.55.0': {} + '@eslint/js@9.21.0': {} + + '@eslint/object-schema@2.1.6': {} + + '@eslint/plugin-kit@0.2.7': + dependencies: + '@eslint/core': 0.12.0 + levn: 0.4.1 '@gar/promisify@1.1.3': {} - '@humanwhocodes/config-array@0.11.14': + '@humanfs/core@0.19.1': {} + + '@humanfs/node@0.16.6': dependencies: - '@humanwhocodes/object-schema': 2.0.3 - debug: 4.4.0 - minimatch: 3.1.2 - transitivePeerDependencies: - - supports-color + '@humanfs/core': 0.19.1 + '@humanwhocodes/retry': 0.3.1 '@humanwhocodes/module-importer@1.0.1': {} - '@humanwhocodes/object-schema@2.0.3': {} + '@humanwhocodes/retry@0.3.1': {} + + '@humanwhocodes/retry@0.4.2': {} '@isaacs/cliui@8.0.2': dependencies: @@ -2128,99 +2289,126 @@ snapshots: '@types/estree@1.0.6': {} + '@types/fs-extra@11.0.4': + dependencies: + '@types/jsonfile': 6.1.4 + '@types/node': 22.10.10 + + '@types/hosted-git-info@3.0.5': {} + '@types/json-schema@7.0.15': {} + '@types/jsonfile@6.1.4': + dependencies: + '@types/node': 22.10.10 + + '@types/make-fetch-happen@10.0.4': + dependencies: + '@types/node-fetch': 2.6.12 + '@types/retry': 0.12.5 + '@types/ssri': 7.1.5 + + '@types/node-fetch@2.6.12': + dependencies: + '@types/node': 22.10.10 + form-data: 4.0.2 + '@types/node@22.10.10': dependencies: undici-types: 6.20.0 - '@types/semver@7.5.8': {} + '@types/progress@2.0.7': + dependencies: + '@types/node': 22.10.10 + + '@types/retry@0.12.5': {} - '@typescript-eslint/eslint-plugin@5.62.0(@typescript-eslint/parser@5.62.0(eslint@8.55.0)(typescript@5.0.4))(eslint@8.55.0)(typescript@5.0.4)': + '@types/ssri@7.1.5': + dependencies: + '@types/node': 22.10.10 + + '@types/yargs-parser@21.0.3': {} + + '@types/yargs@17.0.33': + dependencies: + '@types/yargs-parser': 21.0.3 + + '@typescript-eslint/eslint-plugin@8.25.0(@typescript-eslint/parser@8.25.0(eslint@9.21.0)(typescript@5.7.3))(eslint@9.21.0)(typescript@5.7.3)': dependencies: '@eslint-community/regexpp': 4.12.1 - '@typescript-eslint/parser': 5.62.0(eslint@8.55.0)(typescript@5.0.4) - '@typescript-eslint/scope-manager': 5.62.0 - '@typescript-eslint/type-utils': 5.62.0(eslint@8.55.0)(typescript@5.0.4) - '@typescript-eslint/utils': 5.62.0(eslint@8.55.0)(typescript@5.0.4) - debug: 4.4.0 - eslint: 8.55.0 + '@typescript-eslint/parser': 8.25.0(eslint@9.21.0)(typescript@5.7.3) + '@typescript-eslint/scope-manager': 8.25.0 + '@typescript-eslint/type-utils': 8.25.0(eslint@9.21.0)(typescript@5.7.3) + '@typescript-eslint/utils': 8.25.0(eslint@9.21.0)(typescript@5.7.3) + '@typescript-eslint/visitor-keys': 8.25.0 + eslint: 9.21.0 graphemer: 1.4.0 ignore: 5.3.2 - natural-compare-lite: 1.4.0 - semver: 7.7.1 - tsutils: 3.21.0(typescript@5.0.4) - optionalDependencies: - typescript: 5.0.4 + natural-compare: 1.4.0 + ts-api-utils: 2.0.1(typescript@5.7.3) + typescript: 5.7.3 transitivePeerDependencies: - supports-color - '@typescript-eslint/parser@5.62.0(eslint@8.55.0)(typescript@5.0.4)': + '@typescript-eslint/parser@8.25.0(eslint@9.21.0)(typescript@5.7.3)': dependencies: - '@typescript-eslint/scope-manager': 5.62.0 - '@typescript-eslint/types': 5.62.0 - '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.0.4) + '@typescript-eslint/scope-manager': 8.25.0 + '@typescript-eslint/types': 8.25.0 + '@typescript-eslint/typescript-estree': 8.25.0(typescript@5.7.3) + '@typescript-eslint/visitor-keys': 8.25.0 debug: 4.4.0 - eslint: 8.55.0 - optionalDependencies: - typescript: 5.0.4 + eslint: 9.21.0 + typescript: 5.7.3 transitivePeerDependencies: - supports-color - '@typescript-eslint/scope-manager@5.62.0': + '@typescript-eslint/scope-manager@8.25.0': dependencies: - '@typescript-eslint/types': 5.62.0 - '@typescript-eslint/visitor-keys': 5.62.0 + '@typescript-eslint/types': 8.25.0 + '@typescript-eslint/visitor-keys': 8.25.0 - '@typescript-eslint/type-utils@5.62.0(eslint@8.55.0)(typescript@5.0.4)': + '@typescript-eslint/type-utils@8.25.0(eslint@9.21.0)(typescript@5.7.3)': dependencies: - '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.0.4) - '@typescript-eslint/utils': 5.62.0(eslint@8.55.0)(typescript@5.0.4) + '@typescript-eslint/typescript-estree': 8.25.0(typescript@5.7.3) + '@typescript-eslint/utils': 8.25.0(eslint@9.21.0)(typescript@5.7.3) debug: 4.4.0 - eslint: 8.55.0 - tsutils: 3.21.0(typescript@5.0.4) - optionalDependencies: - typescript: 5.0.4 + eslint: 9.21.0 + ts-api-utils: 2.0.1(typescript@5.7.3) + typescript: 5.7.3 transitivePeerDependencies: - supports-color - '@typescript-eslint/types@5.62.0': {} + '@typescript-eslint/types@8.25.0': {} - '@typescript-eslint/typescript-estree@5.62.0(typescript@5.0.4)': + '@typescript-eslint/typescript-estree@8.25.0(typescript@5.7.3)': dependencies: - '@typescript-eslint/types': 5.62.0 - '@typescript-eslint/visitor-keys': 5.62.0 + '@typescript-eslint/types': 8.25.0 + '@typescript-eslint/visitor-keys': 8.25.0 debug: 4.4.0 - globby: 11.1.0 + fast-glob: 3.3.3 is-glob: 4.0.3 + minimatch: 9.0.5 semver: 7.7.1 - tsutils: 3.21.0(typescript@5.0.4) - optionalDependencies: - typescript: 5.0.4 + ts-api-utils: 2.0.1(typescript@5.7.3) + typescript: 5.7.3 transitivePeerDependencies: - supports-color - '@typescript-eslint/utils@5.62.0(eslint@8.55.0)(typescript@5.0.4)': + '@typescript-eslint/utils@8.25.0(eslint@9.21.0)(typescript@5.7.3)': dependencies: - '@eslint-community/eslint-utils': 4.4.1(eslint@8.55.0) - '@types/json-schema': 7.0.15 - '@types/semver': 7.5.8 - '@typescript-eslint/scope-manager': 5.62.0 - '@typescript-eslint/types': 5.62.0 - '@typescript-eslint/typescript-estree': 5.62.0(typescript@5.0.4) - eslint: 8.55.0 - eslint-scope: 5.1.1 - semver: 7.7.1 + '@eslint-community/eslint-utils': 4.4.1(eslint@9.21.0) + '@typescript-eslint/scope-manager': 8.25.0 + '@typescript-eslint/types': 8.25.0 + '@typescript-eslint/typescript-estree': 8.25.0(typescript@5.7.3) + eslint: 9.21.0 + typescript: 5.7.3 transitivePeerDependencies: - supports-color - - typescript - '@typescript-eslint/visitor-keys@5.62.0': + '@typescript-eslint/visitor-keys@8.25.0': dependencies: - '@typescript-eslint/types': 5.62.0 - eslint-visitor-keys: 3.4.3 - - '@ungap/structured-clone@1.3.0': {} + '@typescript-eslint/types': 8.25.0 + eslint-visitor-keys: 4.2.0 '@vitest/expect@3.0.6': dependencies: @@ -2304,12 +2492,12 @@ snapshots: argparse@2.0.1: {} - array-union@2.1.0: {} - assert-never@1.4.0: {} assertion-error@2.0.1: {} + asynckit@0.4.0: {} + balanced-match@1.0.2: {} before-after-hook@2.2.3: {} @@ -2352,6 +2540,11 @@ snapshots: transitivePeerDependencies: - bluebird + call-bind-apply-helpers@1.0.2: + dependencies: + es-errors: 1.3.0 + function-bind: 1.1.2 + callsites@3.1.0: {} chai@5.2.0: @@ -2400,6 +2593,10 @@ snapshots: color-name@1.1.4: {} + combined-stream@1.0.8: + dependencies: + delayed-stream: 1.0.0 + concat-map@0.0.1: {} config-chain@1.1.13: @@ -2423,15 +2620,15 @@ snapshots: deep-is@0.1.4: {} - deprecation@2.3.1: {} + delayed-stream@1.0.0: {} - dir-glob@3.0.1: - dependencies: - path-type: 4.0.0 + deprecation@2.3.1: {} - doctrine@3.0.0: + dunder-proto@1.0.1: dependencies: - esutils: 2.0.3 + call-bind-apply-helpers: 1.0.2 + es-errors: 1.3.0 + gopd: 1.2.0 eastasianwidth@0.2.0: {} @@ -2448,10 +2645,30 @@ snapshots: dependencies: once: 1.4.0 + enhanced-resolve@5.18.1: + dependencies: + graceful-fs: 4.2.11 + tapable: 2.2.1 + err-code@2.0.3: {} + es-define-property@1.0.1: {} + + es-errors@1.3.0: {} + es-module-lexer@1.6.0: {} + es-object-atoms@1.1.1: + dependencies: + es-errors: 1.3.0 + + es-set-tostringtag@2.1.0: + dependencies: + es-errors: 1.3.0 + get-intrinsic: 1.3.0 + has-tostringtag: 1.0.2 + hasown: 2.0.2 + esbuild@0.24.2: optionalDependencies: '@esbuild/aix-ppc64': 0.24.2 @@ -2484,78 +2701,95 @@ snapshots: escape-string-regexp@4.0.0: {} - eslint-config-prettier@9.1.0(eslint@8.55.0): + eslint-compat-utils@0.5.1(eslint@9.21.0): + dependencies: + eslint: 9.21.0 + semver: 7.7.1 + + eslint-config-prettier@9.1.0(eslint@9.21.0): dependencies: - eslint: 8.55.0 + eslint: 9.21.0 - eslint-plugin-prettier@4.2.1(eslint-config-prettier@9.1.0(eslint@8.55.0))(eslint@8.55.0)(prettier@2.8.8): + eslint-plugin-es-x@7.8.0(eslint@9.21.0): dependencies: - eslint: 8.55.0 - prettier: 2.8.8 - prettier-linter-helpers: 1.0.0 - optionalDependencies: - eslint-config-prettier: 9.1.0(eslint@8.55.0) + '@eslint-community/eslint-utils': 4.4.1(eslint@9.21.0) + '@eslint-community/regexpp': 4.12.1 + eslint: 9.21.0 + eslint-compat-utils: 0.5.1(eslint@9.21.0) - eslint-scope@5.1.1: + eslint-plugin-n@17.15.1(eslint@9.21.0): dependencies: - esrecurse: 4.3.0 - estraverse: 4.3.0 + '@eslint-community/eslint-utils': 4.4.1(eslint@9.21.0) + enhanced-resolve: 5.18.1 + eslint: 9.21.0 + eslint-plugin-es-x: 7.8.0(eslint@9.21.0) + get-tsconfig: 4.10.0 + globals: 15.15.0 + ignore: 5.3.2 + minimatch: 9.0.5 + semver: 7.7.1 + + eslint-plugin-prettier@4.2.1(eslint-config-prettier@9.1.0(eslint@9.21.0))(eslint@9.21.0)(prettier@3.5.2): + dependencies: + eslint: 9.21.0 + prettier: 3.5.2 + prettier-linter-helpers: 1.0.0 + optionalDependencies: + eslint-config-prettier: 9.1.0(eslint@9.21.0) - eslint-scope@7.2.2: + eslint-scope@8.2.0: dependencies: esrecurse: 4.3.0 estraverse: 5.3.0 eslint-visitor-keys@3.4.3: {} - eslint@8.55.0: + eslint-visitor-keys@4.2.0: {} + + eslint@9.21.0: dependencies: - '@eslint-community/eslint-utils': 4.4.1(eslint@8.55.0) + '@eslint-community/eslint-utils': 4.4.1(eslint@9.21.0) '@eslint-community/regexpp': 4.12.1 - '@eslint/eslintrc': 2.1.4 - '@eslint/js': 8.55.0 - '@humanwhocodes/config-array': 0.11.14 + '@eslint/config-array': 0.19.2 + '@eslint/core': 0.12.0 + '@eslint/eslintrc': 3.3.0 + '@eslint/js': 9.21.0 + '@eslint/plugin-kit': 0.2.7 + '@humanfs/node': 0.16.6 '@humanwhocodes/module-importer': 1.0.1 - '@nodelib/fs.walk': 1.2.8 - '@ungap/structured-clone': 1.3.0 + '@humanwhocodes/retry': 0.4.2 + '@types/estree': 1.0.6 + '@types/json-schema': 7.0.15 ajv: 6.12.6 chalk: 4.1.2 cross-spawn: 7.0.6 debug: 4.4.0 - doctrine: 3.0.0 escape-string-regexp: 4.0.0 - eslint-scope: 7.2.2 - eslint-visitor-keys: 3.4.3 - espree: 9.6.1 + eslint-scope: 8.2.0 + eslint-visitor-keys: 4.2.0 + espree: 10.3.0 esquery: 1.6.0 esutils: 2.0.3 fast-deep-equal: 3.1.3 - file-entry-cache: 6.0.1 + file-entry-cache: 8.0.0 find-up: 5.0.0 glob-parent: 6.0.2 - globals: 13.24.0 - graphemer: 1.4.0 ignore: 5.3.2 imurmurhash: 0.1.4 is-glob: 4.0.3 - is-path-inside: 3.0.3 - js-yaml: 4.1.0 json-stable-stringify-without-jsonify: 1.0.1 - levn: 0.4.1 lodash.merge: 4.6.2 minimatch: 3.1.2 natural-compare: 1.4.0 optionator: 0.9.4 - strip-ansi: 6.0.1 - text-table: 0.2.0 transitivePeerDependencies: - supports-color - espree@9.6.1: + espree@10.3.0: dependencies: acorn: 8.14.0 acorn-jsx: 5.3.2(acorn@8.14.0) - eslint-visitor-keys: 3.4.3 + eslint-visitor-keys: 4.2.0 esquery@1.6.0: dependencies: @@ -2565,8 +2799,6 @@ snapshots: dependencies: estraverse: 5.3.0 - estraverse@4.3.0: {} - estraverse@5.3.0: {} estree-walker@3.0.3: @@ -2621,9 +2853,9 @@ snapshots: dependencies: reusify: 1.0.4 - file-entry-cache@6.0.1: + file-entry-cache@8.0.0: dependencies: - flat-cache: 3.2.0 + flat-cache: 4.0.1 fill-range@7.1.1: dependencies: @@ -2634,11 +2866,10 @@ snapshots: locate-path: 6.0.0 path-exists: 4.0.0 - flat-cache@3.2.0: + flat-cache@4.0.1: dependencies: flatted: 3.3.3 keyv: 4.5.4 - rimraf: 3.0.2 flatted@3.3.3: {} @@ -2647,6 +2878,13 @@ snapshots: cross-spawn: 7.0.6 signal-exit: 4.1.0 + form-data@4.0.2: + dependencies: + asynckit: 0.4.0 + combined-stream: 1.0.8 + es-set-tostringtag: 2.1.0 + mime-types: 2.1.35 + fs-extra@10.1.0: dependencies: graceful-fs: 4.2.11 @@ -2662,14 +2900,38 @@ snapshots: fsevents@2.3.3: optional: true + function-bind@1.1.2: {} + get-caller-file@2.0.5: {} + get-intrinsic@1.3.0: + dependencies: + call-bind-apply-helpers: 1.0.2 + es-define-property: 1.0.1 + es-errors: 1.3.0 + es-object-atoms: 1.1.1 + function-bind: 1.1.2 + get-proto: 1.0.1 + gopd: 1.2.0 + has-symbols: 1.1.0 + hasown: 2.0.2 + math-intrinsics: 1.1.0 + + get-proto@1.0.1: + dependencies: + dunder-proto: 1.0.1 + es-object-atoms: 1.1.1 + get-stream@5.2.0: dependencies: pump: 3.0.2 get-stream@6.0.1: {} + get-tsconfig@4.10.0: + dependencies: + resolve-pkg-maps: 1.0.0 + github-changelog@1.2.0: dependencies: '@manypkg/get-packages': 2.2.2 @@ -2711,18 +2973,13 @@ snapshots: once: 1.4.0 path-is-absolute: 1.0.1 - globals@13.24.0: - dependencies: - type-fest: 0.20.2 + globals@14.0.0: {} - globby@11.1.0: - dependencies: - array-union: 2.1.0 - dir-glob: 3.0.1 - fast-glob: 3.3.3 - ignore: 5.3.2 - merge2: 1.4.1 - slash: 3.0.0 + globals@15.15.0: {} + + globals@16.0.0: {} + + gopd@1.2.0: {} graceful-fs@4.2.10: {} @@ -2732,6 +2989,16 @@ snapshots: has-flag@4.0.0: {} + has-symbols@1.1.0: {} + + has-tostringtag@1.0.2: + dependencies: + has-symbols: 1.1.0 + + hasown@2.0.2: + dependencies: + function-bind: 1.1.2 + highlight.js@10.7.3: {} hosted-git-info@4.1.0: @@ -2813,8 +3080,6 @@ snapshots: is-number@7.0.0: {} - is-path-inside@3.0.3: {} - is-plain-object@5.0.0: {} is-stream@2.0.1: {} @@ -2906,6 +3171,8 @@ snapshots: - bluebird - supports-color + math-intrinsics@1.1.0: {} + merge-stream@2.0.0: {} merge2@1.4.1: {} @@ -2915,6 +3182,12 @@ snapshots: braces: 3.0.3 picomatch: 2.3.1 + mime-db@1.52.0: {} + + mime-types@2.1.35: + dependencies: + mime-db: 1.52.0 + mimic-fn@2.1.0: {} minimatch@3.1.2: @@ -2976,8 +3249,6 @@ snapshots: nanoid@3.3.8: {} - natural-compare-lite@1.4.0: {} - natural-compare@1.4.0: {} negotiator@0.6.4: {} @@ -3087,8 +3358,6 @@ snapshots: lru-cache: 10.4.3 minipass: 7.1.2 - path-type@4.0.0: {} - pathe@2.0.3: {} pathval@2.0.0: {} @@ -3109,7 +3378,7 @@ snapshots: dependencies: fast-diff: 1.3.0 - prettier@2.8.8: {} + prettier@3.5.2: {} proc-log@4.2.0: {} @@ -3173,6 +3442,8 @@ snapshots: resolve-from@4.0.0: {} + resolve-pkg-maps@1.0.0: {} + retry@0.12.0: {} reusify@1.0.4: {} @@ -3227,8 +3498,6 @@ snapshots: signal-exit@4.1.0: {} - slash@3.0.0: {} - smart-buffer@4.2.0: {} socks-proxy-agent@6.2.1: @@ -3300,6 +3569,8 @@ snapshots: dependencies: has-flag: 4.0.0 + tapable@2.2.1: {} + tar@6.2.1: dependencies: chownr: 2.0.0 @@ -3309,8 +3580,6 @@ snapshots: mkdirp: 1.0.4 yallist: 4.0.0 - text-table@0.2.0: {} - thenify-all@1.6.0: dependencies: thenify: 3.3.1 @@ -3335,20 +3604,25 @@ snapshots: tr46@0.0.3: {} - tslib@1.14.1: {} - - tsutils@3.21.0(typescript@5.0.4): + ts-api-utils@2.0.1(typescript@5.7.3): dependencies: - tslib: 1.14.1 - typescript: 5.0.4 + typescript: 5.7.3 type-check@0.4.0: dependencies: prelude-ls: 1.2.1 - type-fest@0.20.2: {} + typescript-eslint@8.25.0(eslint@9.21.0)(typescript@5.7.3): + dependencies: + '@typescript-eslint/eslint-plugin': 8.25.0(@typescript-eslint/parser@8.25.0(eslint@9.21.0)(typescript@5.7.3))(eslint@9.21.0)(typescript@5.7.3) + '@typescript-eslint/parser': 8.25.0(eslint@9.21.0)(typescript@5.7.3) + '@typescript-eslint/utils': 8.25.0(eslint@9.21.0)(typescript@5.7.3) + eslint: 9.21.0 + typescript: 5.7.3 + transitivePeerDependencies: + - supports-color - typescript@5.0.4: {} + typescript@5.7.3: {} undici-types@6.20.0: {} diff --git a/src/__mocks__/changelog.ts b/src/__mocks__/changelog.ts index 77fff49..e718d9c 100644 --- a/src/__mocks__/changelog.ts +++ b/src/__mocks__/changelog.ts @@ -1,6 +1,6 @@ -import { Configuration } from "../configuration"; +import { Configuration } from "../configuration.js"; -import Changelog from "../changelog"; +import Changelog from "../changelog.js"; const defaultConfig = { rootPath: "../", diff --git a/src/__mocks__/github-api.ts b/src/__mocks__/github-api.ts index fd7cd46..0d5817d 100644 --- a/src/__mocks__/github-api.ts +++ b/src/__mocks__/github-api.ts @@ -1,4 +1,4 @@ -import GithubAPI from "../github-api"; +import GithubAPI from "../github-api.js"; class MockedGithubAPI extends GithubAPI { protected getAuthToken() { diff --git a/src/changelog.ts b/src/changelog.ts index b24d1f1..f6e5113 100644 --- a/src/changelog.ts +++ b/src/changelog.ts @@ -1,13 +1,12 @@ -const pMap = require("p-map"); -const { resolve, sep } = require("path"); - -import progressBar from "./progress-bar"; -import { Configuration } from "./configuration"; -import findPullRequestId from "./find-pull-request-id"; -import * as Git from "./git"; -import GithubAPI, { GitHubUserResponse } from "./github-api"; -import { CommitInfo, Release } from "./interfaces"; -import MarkdownRenderer from "./markdown-renderer"; +import pMap from "p-map"; +import progressBar from "./progress-bar.js"; +import { Configuration } from "./configuration.js"; +import findPullRequestId from "./find-pull-request-id.js"; +import * as Git from "./git.js"; +import GithubAPI, { GitHubUserResponse } from "./github-api.js"; +import { CommitInfo, Release } from "./interfaces.js"; +import MarkdownRenderer from "./markdown-renderer.js"; +import { resolve, sep } from "path"; const UNRELEASED_TAG = "___unreleased___"; @@ -66,7 +65,7 @@ export default class Changelog { const commits = await this.getCommitInfos(from, to); // Step 6: Group commits by release (local) - let releases = this.groupByRelease(commits); + const releases = this.groupByRelease(commits); // Step 7: Compile list of committers in release (local + remote) await this.fillInContributors(releases); @@ -75,8 +74,7 @@ export default class Changelog { } private async getListOfUniquePackages(sha: string): Promise { - let changedPaths = await Git.changedPaths(sha); - + const changedPaths = await Git.changedPaths(sha); return changedPaths .map(path => this.packageFromPath(path)) .filter(Boolean) @@ -92,7 +90,7 @@ export default class Changelog { // ember-fastboot // ember-fastboot-2-fast-2-furious const foundPackage = this.config.packages.find(p => { - let withSlash = p.path.endsWith(sep) ? p.path : `${p.path}${sep}`; + const withSlash = p.path.endsWith(sep) ? p.path : `${p.path}${sep}`; return absolutePath.startsWith(withSlash); }); @@ -195,7 +193,7 @@ export default class Changelog { // Analyze the commits and group them by tag. // This is useful to generate multiple release logs in case there are // multiple release tags. - let releaseMap: { [id: string]: Release } = {}; + const releaseMap: { [id: string]: Release } = {}; let currentTags = [UNRELEASED_TAG]; for (const commit of commits) { @@ -210,11 +208,11 @@ export default class Changelog { // referencing them. for (const currentTag of currentTags) { if (!releaseMap[currentTag]) { - let date = currentTag === UNRELEASED_TAG ? this.getToday() : commit.date; + const date = currentTag === UNRELEASED_TAG ? this.getToday() : commit.date; releaseMap[currentTag] = { name: currentTag, date, commits: [] }; } - let prUserLogin = commit.githubIssue?.user.login; + const prUserLogin = commit.githubIssue?.user?.login; if (prUserLogin && !this.ignoreCommitter(prUserLogin)) { releaseMap[currentTag].commits.push(commit); } @@ -239,7 +237,7 @@ export default class Changelog { // check whether the commit has any of the labels from the learna.json config. // If not, label this commit with the provided label - let foundLabel = Object.keys(this.config.labels).some(label => labels.indexOf(label.toLowerCase()) !== -1); + const foundLabel = Object.keys(this.config.labels).some(label => labels.indexOf(label.toLowerCase()) !== -1); if (!foundLabel) { labels.push(this.config.wildcardLabel); diff --git a/src/cli.ts b/src/cli.ts index 717594a..6cdea47 100644 --- a/src/cli.ts +++ b/src/cli.ts @@ -1,16 +1,14 @@ -import chalk = require("chalk"); - +import chalk from "chalk"; import { highlight } from "cli-highlight"; - -import Changelog from "./changelog"; -import { load as loadConfig } from "./configuration"; -import ConfigurationError from "./configuration-error"; - +import Changelog from "./changelog.js"; +import { load as loadConfig } from "./configuration.js"; +import ConfigurationError from "./configuration-error.js"; +import Yargs from "yargs"; +import { hideBin } from "yargs/helpers"; const NEXT_VERSION_DEFAULT = "Unreleased"; export async function run() { - const yargs = require("yargs"); - + const yargs = Yargs(hideBin(process.argv)); const argv = yargs .usage("github-changelog [options]") .options({ @@ -59,15 +57,15 @@ export async function run() { ) .epilog("For more information, see https://github.com/embroider-build/github-changelog") .wrap(Math.min(100, yargs.terminalWidth())) - .parse(); + .parseSync(); - let options = { + const options = { tagFrom: argv["from"] || argv["tag-from"], tagTo: argv["to"] || argv["tag-to"], }; try { - let config = loadConfig({ + const config = loadConfig({ nextVersionFromMetadata: argv["next-version-from-metadata"], repo: argv.repo, }); @@ -76,9 +74,9 @@ export async function run() { config.nextVersion = argv["next-version"]; } - let result = await new Changelog(config).createMarkdown(options); + const result = await new Changelog(config).createMarkdown(options); - let highlighted = highlight(result, { + const highlighted = highlight(result, { language: "Markdown", theme: { section: chalk.bold, diff --git a/src/configuration-error.spec.ts b/src/configuration-error.spec.ts index 1559ee3..f20879e 100644 --- a/src/configuration-error.spec.ts +++ b/src/configuration-error.spec.ts @@ -1,4 +1,4 @@ -import ConfigurationError from "./configuration-error"; +import ConfigurationError from "./configuration-error.js"; import { describe, it, expect } from "vitest"; diff --git a/src/configuration-error.ts b/src/configuration-error.ts index 25dd1e6..a9c5b6d 100644 --- a/src/configuration-error.ts +++ b/src/configuration-error.ts @@ -3,9 +3,8 @@ export default class ConfigurationError { public message: string; constructor(message: string) { - // @ts-ignore // eslint-disable-next-line prefer-rest-params - Error.apply(this, arguments); + Error.apply(this, arguments as any); this.message = message; } } diff --git a/src/configuration.spec.ts b/src/configuration.spec.ts index b39bd49..3e457fc 100644 --- a/src/configuration.spec.ts +++ b/src/configuration.spec.ts @@ -1,11 +1,9 @@ -const os = require("os"); -const fs = require("fs-extra"); -const path = require("path"); - -import { findRepoFromPkg, fromPath } from "./configuration"; -import ConfigurationError from "./configuration-error"; - +import os from "os"; +import { findRepoFromPkg, fromPath } from "./configuration.js"; +import ConfigurationError from "./configuration-error.js"; import { describe, it, expect, beforeEach, afterEach } from "vitest"; +import fs from "fs-extra"; +import path from "path"; describe("Configuration", function () { describe("fromPath", function () { diff --git a/src/configuration.ts b/src/configuration.ts index 6d9152c..b67b11e 100644 --- a/src/configuration.ts +++ b/src/configuration.ts @@ -1,10 +1,9 @@ -const fs = require("fs"); -const path = require("path"); -const hostedGitInfo = require("hosted-git-info"); -const { getPackagesSync } = require("@manypkg/get-packages"); - -import ConfigurationError from "./configuration-error"; -import { getRootPath } from "./git"; +import fs from "fs"; +import ConfigurationError from "./configuration-error.js"; +import { getRootPath } from "./git.js"; +import path from "path"; +import { getPackagesSync } from "@manypkg/get-packages"; +import hostedGitInfo from "hosted-git-info"; export interface Configuration { repo: string; @@ -26,33 +25,13 @@ export interface ConfigLoaderOptions { } export function load(options: ConfigLoaderOptions = {}): Configuration { - let rootPath = getRootPath(); + const rootPath = getRootPath(); return fromPath(rootPath, options); } -interface PackageJson { - type: boolean; - private: boolean; - name: string; -} - -interface Package { - dir: string; - relativeDir: string; - packageJson: PackageJson; -} - -interface PackagesResult { - tool: { - type: "pnpm" | "yarn" | "npm"; - }; - packages: Package[]; - rootPackage: Package; -} - function getPackages(rootPath: string): { name: string; path: string }[] { try { - let { packages } = getPackagesSync(rootPath) as PackagesResult; + const { packages } = getPackagesSync(rootPath); return packages .filter(pkg => !pkg.packageJson.private) @@ -78,7 +57,7 @@ function getPackages(rootPath: string): { name: string; path: string }[] { export function fromPath(rootPath: string, options: ConfigLoaderOptions = {}): Configuration { // Step 1: load partial config from `package.json` or `lerna.json` - let config = fromPackageConfig(rootPath) || fromLernaConfig(rootPath) || {}; + const config = fromPackageConfig(rootPath) || fromLernaConfig(rootPath) || {}; if (options.repo) { config.repo = options.repo; @@ -155,14 +134,14 @@ export function fromPath(rootPath: string, options: ConfigLoaderOptions = {}): C function fromLernaConfig(rootPath: string): Partial | undefined { const lernaPath = path.join(rootPath, "lerna.json"); if (fs.existsSync(lernaPath)) { - return JSON.parse(fs.readFileSync(lernaPath)).changelog; + return JSON.parse(fs.readFileSync(lernaPath).toString()).changelog; } } function fromPackageConfig(rootPath: string): Partial | undefined { const pkgPath = path.join(rootPath, "package.json"); if (fs.existsSync(pkgPath)) { - return JSON.parse(fs.readFileSync(pkgPath)).changelog; + return JSON.parse(fs.readFileSync(pkgPath).toString()).changelog; } } @@ -172,7 +151,7 @@ function findRepo(rootPath: string): string | undefined { return; } - const pkg = JSON.parse(fs.readFileSync(pkgPath)); + const pkg = JSON.parse(fs.readFileSync(pkgPath).toString()); if (!pkg.repository) { return; } @@ -184,8 +163,8 @@ function findNextVersion(rootPath: string): string | undefined { const pkgPath = path.join(rootPath, "package.json"); const lernaPath = path.join(rootPath, "lerna.json"); - const pkg = fs.existsSync(pkgPath) ? JSON.parse(fs.readFileSync(pkgPath)) : {}; - const lerna = fs.existsSync(lernaPath) ? JSON.parse(fs.readFileSync(lernaPath)) : {}; + const pkg = fs.existsSync(pkgPath) ? JSON.parse(fs.readFileSync(pkgPath).toString()) : {}; + const lerna = fs.existsSync(lernaPath) ? JSON.parse(fs.readFileSync(lernaPath).toString()) : {}; return pkg.version ? `v${pkg.version}` : lerna.version ? `v${lerna.version}` : undefined; } @@ -199,11 +178,11 @@ export function findRepoFromPkg(pkg: any): string | undefined { // cannot detect self hosted GitHub, e.g // git@github.host.com:embroider-build/github-changelog.git // https://github.host.com/embroider-build/github-changelog.git - const matchHttps = /https:\/\/[^\/]+\/([^\/]+)\/([^\/]+)\.git/.exec(url); + const matchHttps = /https:\/\/[^/]+\/([^/]+)\/([^/]+)\.git/.exec(url); if (matchHttps && matchHttps.length === 3) { return `${matchHttps[1]}/${matchHttps[2]}`; } - const matchGit = /git@[^:]+:([^\/]+)\/([^\/]+)\.git/.exec(url); + const matchGit = /git@[^:]+:([^/]+)\/([^/]+)\.git/.exec(url); if (matchGit && matchGit.length === 3) { return `${matchGit[1]}/${matchGit[2]}`; } diff --git a/src/fetch.ts b/src/fetch.ts index f8a973b..37fd430 100644 --- a/src/fetch.ts +++ b/src/fetch.ts @@ -1,3 +1,3 @@ -const fetch = require("make-fetch-happen"); +import fetch from "make-fetch-happen"; export default fetch; diff --git a/src/find-pull-request-id.spec.ts b/src/find-pull-request-id.spec.ts index f1cbf4b..3d48a04 100644 --- a/src/find-pull-request-id.spec.ts +++ b/src/find-pull-request-id.spec.ts @@ -1,4 +1,4 @@ -import findPullRequestId from "./find-pull-request-id"; +import findPullRequestId from "./find-pull-request-id.js"; import { describe, it, expect } from "vitest"; diff --git a/src/functional/markdown-empty.spec.js b/src/functional/markdown-empty.spec.js index 5b07ffc..e56d621 100644 --- a/src/functional/markdown-empty.spec.js +++ b/src/functional/markdown-empty.spec.js @@ -1,5 +1,3 @@ -import { CommitListItem } from "../git"; - import { vi, describe, it, beforeEach, afterEach, expect } from "vitest"; import * as fetch from "../fetch"; diff --git a/src/functional/markdown-full.spec.js b/src/functional/markdown-full.spec.js index b709b98..1f1f4da 100644 --- a/src/functional/markdown-full.spec.js +++ b/src/functional/markdown-full.spec.js @@ -1,5 +1,3 @@ -import { CommitListItem } from "../git"; - import { vi, describe, beforeEach, afterEach, it, expect } from "vitest"; import * as git from "../git"; diff --git a/src/git.spec.ts b/src/git.spec.ts index ee51c2b..55cfbfb 100644 --- a/src/git.spec.ts +++ b/src/git.spec.ts @@ -1,4 +1,4 @@ -import { parseLogMessage } from "./git"; +import { parseLogMessage } from "./git.js"; import { describe, it, expect } from "vitest"; const messages = [ diff --git a/src/git.ts b/src/git.ts index edc0a39..558d2f3 100644 --- a/src/git.ts +++ b/src/git.ts @@ -1,4 +1,4 @@ -const execa = require("execa"); +import execa from "execa"; export function getRootPath() { const cwd = process.cwd(); @@ -61,5 +61,5 @@ export function listCommits(from: string, to: string = ""): CommitListItem[] { .stdout.split("\n") .filter(Boolean) .map(parseLogMessage) - .filter(Boolean); + .filter(Boolean) as CommitListItem[]; } diff --git a/src/github-api.spec.ts b/src/github-api.spec.ts index 842b4e6..7873eaf 100644 --- a/src/github-api.spec.ts +++ b/src/github-api.spec.ts @@ -1,4 +1,4 @@ -import GithubAPI from "./github-api"; +import GithubAPI from "./github-api.js"; import { describe, it, expect } from "vitest"; describe("github api", function () { diff --git a/src/github-api.ts b/src/github-api.ts index 45af424..ca97e1e 100644 --- a/src/github-api.ts +++ b/src/github-api.ts @@ -1,7 +1,6 @@ -const path = require("path"); - -import ConfigurationError from "./configuration-error"; -import fetch from "./fetch"; +import path from "path"; +import ConfigurationError from "./configuration-error.js"; +import fetch from "./fetch.js"; export interface GitHubUserResponse { login: string; diff --git a/src/index.ts b/src/index.ts index 90af90f..3b4833b 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,4 +1,4 @@ -import Changelog from "./changelog"; -import ConfigurationError from "./configuration-error"; +import Changelog from "./changelog.js"; +import ConfigurationError from "./configuration-error.js"; export { Changelog, ConfigurationError }; diff --git a/src/interfaces.ts b/src/interfaces.ts index 1452cc6..c180cc3 100644 --- a/src/interfaces.ts +++ b/src/interfaces.ts @@ -1,4 +1,4 @@ -import { GitHubIssueResponse, GitHubUserResponse } from "./github-api"; +import { GitHubIssueResponse, GitHubUserResponse } from "./github-api.js"; export interface CommitInfo { commitSHA: string; diff --git a/src/markdown-renderer.spec.ts b/src/markdown-renderer.spec.ts index 1659fe9..9926db6 100644 --- a/src/markdown-renderer.spec.ts +++ b/src/markdown-renderer.spec.ts @@ -1,5 +1,5 @@ -import { CommitInfo, Release } from "./interfaces"; -import MarkdownRenderer from "./markdown-renderer"; +import { CommitInfo, Release } from "./interfaces.js"; +import MarkdownRenderer from "./markdown-renderer.js"; import { describe, it, expect } from "vitest"; diff --git a/src/markdown-renderer.ts b/src/markdown-renderer.ts index 61544d3..7a657a5 100644 --- a/src/markdown-renderer.ts +++ b/src/markdown-renderer.ts @@ -1,5 +1,5 @@ -import { GitHubUserResponse } from "./github-api"; -import { CommitInfo, Release } from "./interfaces"; +import { GitHubUserResponse } from "./github-api.js"; +import { CommitInfo, Release } from "./interfaces.js"; const UNRELEASED_TAG = "___unreleased___"; const COMMIT_FIX_REGEX = /(fix|close|resolve)(e?s|e?d)? [T#](\d+)/i; @@ -23,7 +23,7 @@ export default class MarkdownRenderer { } public renderMarkdown(releases: Release[]) { - let output = releases + const output = releases .map(release => this.renderRelease(release)) .filter(Boolean) .join("\n\n\n"); @@ -137,7 +137,7 @@ export default class MarkdownRenderer { return this.options.categories.map(name => { // Keep only the commits that have a matching label with the one // provided in the lerna.json config. - let commits = allCommits.filter(commit => commit.categories && commit.categories.indexOf(name) !== -1); + const commits = allCommits.filter(commit => commit.categories && commit.categories.indexOf(name) !== -1); return { name, commits }; }); diff --git a/src/progress-bar.ts b/src/progress-bar.ts index b91f70c..736a0c8 100644 --- a/src/progress-bar.ts +++ b/src/progress-bar.ts @@ -1,6 +1,5 @@ -import chalk = require("chalk"); - -const ProgressBar = require("progress"); +import * as chalk from "chalk"; +import ProgressBar from "progress"; class ProgressBarController { private bar: any; diff --git a/tsconfig.json b/tsconfig.json index e8bddbb..811d0f2 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,13 +1,22 @@ { "compilerOptions": { - "outDir": "lib", - "target": "es2015", - "module": "CommonJS", - "removeComments": true, - "allowJs": true, + "target": "es2022", + "module": "NodeNext", + "declaration": true, + "typeRoots": ["types", "node_modules/@types"], + "esModuleInterop": true, + "moduleResolution": "nodenext", + "noUnusedLocals": true, + "noUnusedParameters": true, + "sourceMap": true, + "inlineSources": true, + "experimentalDecorators": true, + "allowUnreachableCode": false, "strict": true, - "lib": ["es2015"], "skipLibCheck": true, + "useUnknownInCatchVariables": false, + "rootDir": "./src", + "outDir": "./lib" }, "include": ["src/**/*.ts"] }