From ef379401293a8f21b08f75bdcbd8cea2cafa789c Mon Sep 17 00:00:00 2001 From: Almanov Nikita <131481562+nikkeyl@users.noreply.github.com> Date: Fri, 9 Aug 2024 12:22:30 +0300 Subject: [PATCH] refactor: add `d.ts` file in root --- index.d.ts | 12 ++++++ package.json | 6 +-- pnpm-lock.yaml | 99 ++++++++++++++++++++++++++++---------------------- 3 files changed, 70 insertions(+), 47 deletions(-) create mode 100644 index.d.ts diff --git a/index.d.ts b/index.d.ts new file mode 100644 index 0000000..95427ef --- /dev/null +++ b/index.d.ts @@ -0,0 +1,12 @@ +import { UserConfig } from '@commitlint/types'; + +/** + * Define an Commitlint config. + * + * @param {object} config Commitlint config. + * + * @returns Commitlint config. + */ +declare const defineConfig: (config: UserConfig) => UserConfig; + +export { defineConfig }; diff --git a/package.json b/package.json index df82669..ff57bee 100644 --- a/package.json +++ b/package.json @@ -68,10 +68,10 @@ "@commitlint/types": "^19.0.0" }, "devDependencies": { - "@archoleat/commitlint-define-config": "^1.0.7", + "@archoleat/commitlint-define-config": "file:", "@archoleat/eslint-flat-compatibility": "^1.1.6", - "@archoleat/semantic-release-define-config": "^1.1.12", - "@commitlint/cli": "^19.3.0", + "@archoleat/semantic-release-define-config": "^1.1.13", + "@commitlint/cli": "^19.4.0", "@commitlint/config-conventional": "^19.2.2", "@commitlint/types": "^19.0.3", "@rollup/plugin-typescript": "^11.1.6", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index c8e9697..1ad17b0 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -9,17 +9,17 @@ importers: .: devDependencies: '@archoleat/commitlint-define-config': - specifier: ^1.0.7 - version: 1.0.7 + specifier: 'file:' + version: file:(@commitlint/cli@19.4.0(@types/node@22.1.0)(typescript@5.5.4))(@commitlint/config-conventional@19.2.2)(@commitlint/types@19.0.3) '@archoleat/eslint-flat-compatibility': specifier: ^1.1.6 version: 1.1.6 '@archoleat/semantic-release-define-config': - specifier: ^1.1.12 - version: 1.1.12(semantic-release@24.0.0(typescript@5.5.4)) + specifier: ^1.1.13 + version: 1.1.13(semantic-release@24.0.0(typescript@5.5.4)) '@commitlint/cli': - specifier: ^19.3.0 - version: 19.3.0(@types/node@22.1.0)(typescript@5.5.4) + specifier: ^19.4.0 + version: 19.4.0(@types/node@22.1.0)(typescript@5.5.4) '@commitlint/config-conventional': specifier: ^19.2.2 version: 19.2.2 @@ -129,16 +129,20 @@ packages: resolution: {integrity: sha512-30iZtAPgz+LTIYoeivqYo853f02jBYSd5uGnGpkFV0M3xOt9aN73erkgYAmZU43x4VfqcnLxW9Kpg3R5LC4YYw==} engines: {node: '>=6.0.0'} - '@archoleat/commitlint-define-config@1.0.7': - resolution: {integrity: sha512-2ekyjrJFJDk2t+13O65mmlekiZypGDnh7VXSq6fk4X9jExx4LQ7BgQSEEMS4DpM0ce3vjtAgQejEHyS9bzDyWA==} - engines: {node: '>=20.0.0', npm: '>=10.0.0', pnpm: '>=8.0.0'} + '@archoleat/commitlint-define-config@file:': + resolution: {directory: '', type: directory} + engines: {node: '>=20.0.0', pnpm: '>=9.0.0'} + peerDependencies: + '@commitlint/cli': ^19.0.0 + '@commitlint/config-conventional': ^19.0.0 + '@commitlint/types': ^19.0.0 '@archoleat/eslint-flat-compatibility@1.1.6': resolution: {integrity: sha512-gu8PQv6hWh2DEm2FONtAPDvv1odZXCADshCyvouYzFNscEgMLW0zwbfv6d6pAlsk7uY9+V05R/tz0qv0Sy4mzg==} engines: {node: '>=20.0.0', npm: '>=10.0.0', pnpm: '>=8.0.0'} - '@archoleat/semantic-release-define-config@1.1.12': - resolution: {integrity: sha512-oZnq/ouabo6lvAxcSZr4DQmk4oETz2p27hFgmcjTNrzo5qoWtm80Fpk3Y1r42b9r+a8s5Y6kbaa5a195nTNG5g==} + '@archoleat/semantic-release-define-config@1.1.13': + resolution: {integrity: sha512-MwpD6NHfsLM4ZABwp5SitsyzamDO8dh/rvwNjuBXRIHj8L1ljpsmQCuSz8ZwTJTH5EnKEoXIpdnLZlNI52IpTA==} engines: {node: '>=20.0.0', pnpm: '>=9.0.0'} peerDependencies: semantic-release: ^23.0.0 || ^24.0.0 @@ -175,8 +179,8 @@ packages: resolution: {integrity: sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==} engines: {node: '>=0.1.90'} - '@commitlint/cli@19.3.0': - resolution: {integrity: sha512-LgYWOwuDR7BSTQ9OLZ12m7F/qhNY+NpAyPBgo4YNMkACE7lGuUnuQq1yi9hz1KA4+3VqpOYl8H1rY/LYK43v7g==} + '@commitlint/cli@19.4.0': + resolution: {integrity: sha512-sJX4J9UioVwZHq7JWM9tjT5bgWYaIN3rC4FP7YwfEwBYiIO+wMyRttRvQLNkow0vCdM0D67r9NEWU0Ui03I4Eg==} engines: {node: '>=v18'} hasBin: true @@ -208,8 +212,8 @@ packages: resolution: {integrity: sha512-xrzMmz4JqwGyKQKTpFzlN0dx0TAiT7Ran1fqEBgEmEj+PU98crOFtysJgY+QdeSagx6EDRigQIXJVnfrI0ratA==} engines: {node: '>=v18'} - '@commitlint/load@19.2.0': - resolution: {integrity: sha512-XvxxLJTKqZojCxaBQ7u92qQLFMMZc4+p9qrIq/9kJDy8DOrEa7P1yx7Tjdc2u2JxIalqT4KOGraVgCE7eCYJyQ==} + '@commitlint/load@19.4.0': + resolution: {integrity: sha512-I4lCWaEZYQJ1y+Y+gdvbGAx9pYPavqZAZ3/7/8BpWh+QjscAn8AjsUpLV2PycBsEx7gupq5gM4BViV9xwTIJuw==} engines: {node: '>=v18'} '@commitlint/message@19.0.0': @@ -220,8 +224,8 @@ packages: resolution: {integrity: sha512-Il+tNyOb8VDxN3P6XoBBwWJtKKGzHlitEuXA5BP6ir/3loWlsSqDr5aecl6hZcC/spjq4pHqNh0qPlfeWu38QA==} engines: {node: '>=v18'} - '@commitlint/read@19.2.1': - resolution: {integrity: sha512-qETc4+PL0EUv7Q36lJbPG+NJiBOGg7SSC7B5BsPWOmei+Dyif80ErfWQ0qXoW9oCh7GTpTNRoaVhiI8RbhuaNw==} + '@commitlint/read@19.4.0': + resolution: {integrity: sha512-r95jLOEZzKDakXtnQub+zR3xjdnrl2XzerPwm7ch1/cc5JGq04tyaNpa6ty0CRCWdVrk4CZHhqHozb8yZwy2+g==} engines: {node: '>=v18'} '@commitlint/resolve-extends@19.1.0': @@ -1038,8 +1042,8 @@ packages: resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==} engines: {node: '>=6'} - caniuse-lite@1.0.30001649: - resolution: {integrity: sha512-fJegqZZ0ZX8HOWr6rcafGr72+xcgJKI9oWfDW5DrD7ExUtgZC7a7R7ZYmZqplh7XDocFdGeIFn7roAxhOeYrPQ==} + caniuse-lite@1.0.30001651: + resolution: {integrity: sha512-9Cf+Xv1jJNe1xPZLGuUXLNkE1BoDkqRqYyFJ9TDYSqhduqA4hu4oR9HluGoWYQC/aj8WHjsGVV+bwkh0+tegRg==} ccount@2.0.1: resolution: {integrity: sha512-eyrF0jiFpY+3drT6383f1qhkbGsLSifNAjA61IUjZjmLCWjItY6LB9ft9YhoDgwfmclB2zhu51Lc7+95b8NRAg==} @@ -1697,8 +1701,8 @@ packages: for-each@0.3.3: resolution: {integrity: sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==} - foreground-child@3.2.1: - resolution: {integrity: sha512-PXUUyLqrR2XCWICfv6ukppP96sdFwWbNEnfEMt7jNsISjMsvaLNinAHNDYyvkyU+SZG2BTSbT5NjG+vZslfGTA==} + foreground-child@3.3.0: + resolution: {integrity: sha512-Ld2g8rrAyMYFXBhEqMz8ZAHBi4J4uS1i/CxGMDnjyFWddMXLVcDp051DZfu+t7+ab7Wv6SMqpWmyFIj5UbfFvg==} engines: {node: '>=14'} from2@2.3.0: @@ -3686,8 +3690,8 @@ packages: resolution: {integrity: sha512-tLq3bSNx+xSpwvAJnzrK0Ep5CLNWjvFTOp71URMaAEWBfRb9nnJiBoUe0tF8bI4ZFO3omgBR6NvnbzVUT3Ly4g==} engines: {node: '>=14.16'} - type-fest@4.23.0: - resolution: {integrity: sha512-ZiBujro2ohr5+Z/hZWHESLz3g08BBdrdLMieYFULJO+tWc437sn8kQsWLJoZErY8alNhxre9K4p3GURAG11n+w==} + type-fest@4.24.0: + resolution: {integrity: sha512-spAaHzc6qre0TlZQQ2aA/nGMe+2Z/wyGk5Z+Ru2VUfdNwT6kWO6TjevOlpebsATEG1EIQ2sOiDszud3lO5mt/Q==} engines: {node: '>=16'} typed-array-buffer@1.0.2: @@ -3829,8 +3833,8 @@ packages: engines: {node: ^18.0.0 || >=20.0.0} hasBin: true - vite@5.3.5: - resolution: {integrity: sha512-MdjglKR6AQXQb9JGiS7Rc2wC6uMjcm7Go/NHNO63EwiJXfuk9PgqiP/n5IDJCziMkfw9n4Ubp7lttNwz+8ZVKA==} + vite@5.4.0: + resolution: {integrity: sha512-5xokfMX0PIiwCMCMb9ZJcMyh5wbBun0zUzKib+L65vAZ8GY9ePZMXxFrHbr/Kyll2+LSCY7xtERPpxkBDKngwg==} engines: {node: ^18.0.0 || >=20.0.0} hasBin: true peerDependencies: @@ -3838,6 +3842,7 @@ packages: less: '*' lightningcss: ^1.21.0 sass: '*' + sass-embedded: '*' stylus: '*' sugarss: '*' terser: ^5.4.0 @@ -3850,6 +3855,8 @@ packages: optional: true sass: optional: true + sass-embedded: + optional: true stylus: optional: true sugarss: @@ -3991,8 +3998,10 @@ snapshots: '@jridgewell/gen-mapping': 0.3.5 '@jridgewell/trace-mapping': 0.3.25 - '@archoleat/commitlint-define-config@1.0.7': + '@archoleat/commitlint-define-config@file:(@commitlint/cli@19.4.0(@types/node@22.1.0)(typescript@5.5.4))(@commitlint/config-conventional@19.2.2)(@commitlint/types@19.0.3)': dependencies: + '@commitlint/cli': 19.4.0(@types/node@22.1.0)(typescript@5.5.4) + '@commitlint/config-conventional': 19.2.2 '@commitlint/types': 19.0.3 '@archoleat/eslint-flat-compatibility@1.1.6': @@ -4004,7 +4013,7 @@ snapshots: transitivePeerDependencies: - supports-color - '@archoleat/semantic-release-define-config@1.1.12(semantic-release@24.0.0(typescript@5.5.4))': + '@archoleat/semantic-release-define-config@1.1.13(semantic-release@24.0.0(typescript@5.5.4))': dependencies: semantic-release: 24.0.0(typescript@5.5.4) @@ -4039,12 +4048,12 @@ snapshots: '@colors/colors@1.5.0': optional: true - '@commitlint/cli@19.3.0(@types/node@22.1.0)(typescript@5.5.4)': + '@commitlint/cli@19.4.0(@types/node@22.1.0)(typescript@5.5.4)': dependencies: '@commitlint/format': 19.3.0 '@commitlint/lint': 19.2.2 - '@commitlint/load': 19.2.0(@types/node@22.1.0)(typescript@5.5.4) - '@commitlint/read': 19.2.1 + '@commitlint/load': 19.4.0(@types/node@22.1.0)(typescript@5.5.4) + '@commitlint/read': 19.4.0 '@commitlint/types': 19.0.3 execa: 8.0.1 yargs: 17.7.2 @@ -4090,7 +4099,7 @@ snapshots: '@commitlint/rules': 19.0.3 '@commitlint/types': 19.0.3 - '@commitlint/load@19.2.0(@types/node@22.1.0)(typescript@5.5.4)': + '@commitlint/load@19.4.0(@types/node@22.1.0)(typescript@5.5.4)': dependencies: '@commitlint/config-validator': 19.0.3 '@commitlint/execute-rule': 19.0.0 @@ -4114,7 +4123,7 @@ snapshots: conventional-changelog-angular: 7.0.0 conventional-commits-parser: 5.0.0 - '@commitlint/read@19.2.1': + '@commitlint/read@19.4.0': dependencies: '@commitlint/top-level': 19.0.0 '@commitlint/types': 19.0.3 @@ -4969,7 +4978,7 @@ snapshots: browserslist@4.23.3: dependencies: - caniuse-lite: 1.0.30001649 + caniuse-lite: 1.0.30001651 electron-to-chromium: 1.5.5 node-releases: 2.0.18 update-browserslist-db: 1.1.0(browserslist@4.23.3) @@ -4997,7 +5006,7 @@ snapshots: callsites@3.1.0: {} - caniuse-lite@1.0.30001649: {} + caniuse-lite@1.0.30001651: {} ccount@2.0.1: {} @@ -5256,7 +5265,7 @@ snapshots: longest: 2.0.1 word-wrap: 1.2.5 optionalDependencies: - '@commitlint/load': 19.2.0(@types/node@22.1.0)(typescript@5.5.4) + '@commitlint/load': 19.4.0(@types/node@22.1.0)(typescript@5.5.4) transitivePeerDependencies: - '@types/node' - typescript @@ -5839,7 +5848,7 @@ snapshots: dependencies: is-callable: 1.2.7 - foreground-child@3.2.1: + foreground-child@3.3.0: dependencies: cross-spawn: 7.0.3 signal-exit: 4.1.0 @@ -5952,7 +5961,7 @@ snapshots: glob@10.4.5: dependencies: - foreground-child: 3.2.1 + foreground-child: 3.3.0 jackspeak: 3.4.3 minimatch: 9.0.5 minipass: 7.1.2 @@ -7085,7 +7094,7 @@ snapshots: dependencies: '@babel/code-frame': 7.24.7 index-to-position: 0.1.2 - type-fest: 4.23.0 + type-fest: 4.24.0 parse-ms@4.0.0: {} @@ -7192,7 +7201,7 @@ snapshots: dependencies: find-up-simple: 1.0.0 read-pkg: 9.0.1 - type-fest: 4.23.0 + type-fest: 4.24.0 read-pkg-up@7.0.1: dependencies: @@ -7212,7 +7221,7 @@ snapshots: '@types/normalize-package-data': 2.4.4 normalize-package-data: 6.0.2 parse-json: 8.1.0 - type-fest: 4.23.0 + type-fest: 4.24.0 unicorn-magic: 0.1.0 readable-stream@2.3.8: @@ -8293,7 +8302,7 @@ snapshots: type-fest@3.13.1: {} - type-fest@4.23.0: {} + type-fest@4.24.0: {} typed-array-buffer@1.0.2: dependencies: @@ -8523,18 +8532,19 @@ snapshots: debug: 4.3.6 pathe: 1.1.2 tinyrainbow: 1.2.0 - vite: 5.3.5(@types/node@22.1.0) + vite: 5.4.0(@types/node@22.1.0) transitivePeerDependencies: - '@types/node' - less - lightningcss - sass + - sass-embedded - stylus - sugarss - supports-color - terser - vite@5.3.5(@types/node@22.1.0): + vite@5.4.0(@types/node@22.1.0): dependencies: esbuild: 0.21.5 postcss: 8.4.41 @@ -8561,7 +8571,7 @@ snapshots: tinybench: 2.9.0 tinypool: 1.0.0 tinyrainbow: 1.2.0 - vite: 5.3.5(@types/node@22.1.0) + vite: 5.4.0(@types/node@22.1.0) vite-node: 2.0.5(@types/node@22.1.0) why-is-node-running: 2.3.0 optionalDependencies: @@ -8570,6 +8580,7 @@ snapshots: - less - lightningcss - sass + - sass-embedded - stylus - sugarss - supports-color