From 3f69913ddcba3fa775a088165a7e8b99f8cee814 Mon Sep 17 00:00:00 2001 From: Neko Ayaka Date: Thu, 20 Feb 2025 13:25:34 +0800 Subject: [PATCH] chore(workflow): introduce changelogithub --- .github/workflows/release-pkg.yaml | 11 ++++ changelogithub.config.ts | 3 + cspell.config.yaml | 1 + package.json | 1 + pnpm-lock.yaml | 96 +++++++++++++++++++++++++++++- 5 files changed, 111 insertions(+), 1 deletion(-) create mode 100644 changelogithub.config.ts diff --git a/.github/workflows/release-pkg.yaml b/.github/workflows/release-pkg.yaml index 321ecc729..af9c20072 100644 --- a/.github/workflows/release-pkg.yaml +++ b/.github/workflows/release-pkg.yaml @@ -8,6 +8,12 @@ on: env: STORE_PATH: '' +permissions: + contents: write + issues: write + pull-requests: write + id-token: write + jobs: release: name: Release @@ -53,3 +59,8 @@ jobs: env: NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}} NPM_CONFIG_PROVENANCE: true + + - name: Sync GitHub Release + run: pnpm run changelogithub + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/changelogithub.config.ts b/changelogithub.config.ts new file mode 100644 index 000000000..85c7b2d77 --- /dev/null +++ b/changelogithub.config.ts @@ -0,0 +1,3 @@ +import { defineConfig } from 'changelogithub' + +export default defineConfig({ draft: true }) diff --git a/cspell.config.yaml b/cspell.config.yaml index 3420e69f7..e7a7dcd7f 100644 --- a/cspell.config.yaml +++ b/cspell.config.yaml @@ -17,6 +17,7 @@ words: - Bitstream - bumpp - catppuccin + - changelogithub - cientos - collectblock - composables diff --git a/package.json b/package.json index 40636e3b4..0110fde42 100644 --- a/package.json +++ b/package.json @@ -38,6 +38,7 @@ "@unocss/eslint-plugin": "^65.5.0", "@vitest/coverage-v8": "3.0.5", "bumpp": "^10.0.3", + "changelogithub": "^13.12.1", "cross-env": "^7.0.3", "eslint": "^9.20.1", "eslint-plugin-cypress": "^4.1.0", diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 7599b017b..360fa5721 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -59,6 +59,9 @@ importers: bumpp: specifier: ^10.0.3 version: 10.0.3(magicast@0.3.5) + changelogithub: + specifier: ^13.12.1 + version: 13.12.1(magicast@0.3.5) cross-env: specifier: ^7.0.3 version: 7.0.3 @@ -5469,6 +5472,14 @@ packages: resolution: {integrity: sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==} engines: {node: '>= 0.8'} + c12@1.11.2: + resolution: {integrity: sha512-oBs8a4uvSDO9dm8b7OCFW7+dgtVrwmwnrVXYzLm43ta7ep2jCn/0MhoUFygIWtxhyy6+/MG7/agvpY0U1Iemew==} + peerDependencies: + magicast: ^0.3.4 + peerDependenciesMeta: + magicast: + optional: true + c12@2.0.1: resolution: {integrity: sha512-Z4JgsKXHG37C6PYUtIxCfLJZvo6FyhHJoClwwb9ftUkLpPSkuYqn6Tr+vnaN8hymm0kIbcg6Ey3kv/Q71k5w/A==} peerDependencies: @@ -5541,6 +5552,15 @@ packages: resolution: {integrity: sha512-zgVZuo2WcZgfUEmsn6eO3kINexW8RAE4maiQ8QNs8CtpPCSyMiYsULR3HQYkm3w8FIA3SberyMJMSldGsW+U3w==} engines: {node: ^12.17.0 || ^14.13 || >=16.0.0} + changelogen@0.5.7: + resolution: {integrity: sha512-cTZXBcJMl3pudE40WENOakXkcVtrbBpbkmSkM20NdRiUqa4+VYRdXdEsgQ0BNQ6JBE2YymTNWtPKVF7UCTN5+g==} + hasBin: true + + changelogithub@13.12.1: + resolution: {integrity: sha512-TS8pF9/MzaYVBiKweWujpazs5e5cpwwaEJk6fqYD/rmjnqUGyFq4zMy5HRCVARBgdF2K3sDyeRiSvAXyO0Xwpw==} + engines: {node: '>=12.0.0'} + hasBin: true + character-entities-html4@2.1.0: resolution: {integrity: sha512-1v7fgQRj6hnSwFpq1Eu0ynr/CDEw0rXo2B61qXrLNdHZmPKgb7fqS1a2JwF0rISo9q77jDI8VMEHoApn8qDoZA==} @@ -5767,6 +5787,9 @@ packages: resolution: {integrity: sha512-nTjqfcBFEipKdXCv4YDQWCfmcLZKm81ldF0pAopTvyrFGVbcR6P/VAAd5G7N+0tTr8QqiU0tFadD6FK4NtJwOA==} engines: {node: '>= 0.6'} + convert-gitmoji@0.1.5: + resolution: {integrity: sha512-4wqOafJdk2tqZC++cjcbGcaJ13BZ3kwldf06PTiAQRAB76Z1KJwZNL1SaRZMi2w1FM9RYTgZ6QErS8NUl/GBmQ==} + convert-source-map@2.0.0: resolution: {integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==} @@ -6729,6 +6752,10 @@ packages: resolution: {integrity: sha512-QY5PPtSonnGwhhHDNI7+3RvY285c7iuJFFB+lU+oEzMY/gEGJ808owqJsrr8Otd1E/x07po1LkUBmdAc5duPAg==} engines: {node: ^18.19.0 || >=20.5.0} + execa@9.5.2: + resolution: {integrity: sha512-EHlpxMCpHWSAh1dgS6bVeoLAXGnJNdR93aabr4QCGbzOM73o5XmRfM/e5FUqsw3aagP8S8XEWUWFAxnRBnAF0Q==} + engines: {node: ^18.19.0 || >=20.5.0} + expect-type@1.1.0: resolution: {integrity: sha512-bFi65yM+xZgk+u/KRIpekdSYkTB5W1pEf0Lt8Q8Msh7b+eQ7LXVtIB1Bkm4fvclDEL1b2CZkMhv2mOeF8tMdkA==} engines: {node: '>=12.0.0'} @@ -14561,7 +14588,7 @@ snapshots: dependencies: '@typeschema/core': 0.14.0(@types/json-schema@7.0.15) optionalDependencies: - '@typeschema/valibot': 0.14.0(@gcornut/valibot-json-schema@0.42.0(esbuild@0.25.0)(typescript@5.7.3))(@types/json-schema@7.0.15)(valibot@1.0.0-beta.9(typescript@5.7.3)) + '@typeschema/valibot': 0.14.0(@gcornut/valibot-json-schema@0.42.0(esbuild@0.24.2)(typescript@5.7.3))(@types/json-schema@7.0.15)(valibot@1.0.0-beta.9(typescript@5.7.3)) '@typeschema/zod': 0.14.0(@types/json-schema@7.0.15)(zod-to-json-schema@3.24.1(zod@3.24.2))(zod@3.24.2) transitivePeerDependencies: - '@types/json-schema' @@ -16119,6 +16146,23 @@ snapshots: bytes@3.1.2: {} + c12@1.11.2(magicast@0.3.5): + dependencies: + chokidar: 3.6.0 + confbox: 0.1.8 + defu: 6.1.4 + dotenv: 16.4.7 + giget: 1.2.3 + jiti: 1.21.6 + mlly: 1.7.4 + ohash: 1.1.4 + pathe: 1.1.2 + perfect-debounce: 1.0.0 + pkg-types: 1.3.1 + rc9: 2.1.2 + optionalDependencies: + magicast: 0.3.5 + c12@2.0.1(magicast@0.3.5): dependencies: chokidar: 4.0.1 @@ -16206,6 +16250,39 @@ snapshots: chalk@5.4.1: {} + changelogen@0.5.7(magicast@0.3.5): + dependencies: + c12: 1.11.2(magicast@0.3.5) + colorette: 2.0.20 + consola: 3.4.0 + convert-gitmoji: 0.1.5 + mri: 1.2.0 + node-fetch-native: 1.6.4 + ofetch: 1.4.1 + open: 10.1.0 + pathe: 1.1.2 + pkg-types: 1.3.1 + scule: 1.3.0 + semver: 7.7.1 + std-env: 3.8.0 + yaml: 2.7.0 + transitivePeerDependencies: + - magicast + + changelogithub@13.12.1(magicast@0.3.5): + dependencies: + '@antfu/utils': 8.1.0 + c12: 2.0.1(magicast@0.3.5) + cac: 6.7.14 + changelogen: 0.5.7(magicast@0.3.5) + convert-gitmoji: 0.1.5 + execa: 9.5.2 + kolorist: 1.8.0 + ofetch: 1.4.1 + semver: 7.7.1 + transitivePeerDependencies: + - magicast + character-entities-html4@2.1.0: {} character-entities-legacy@3.0.0: {} @@ -16438,6 +16515,8 @@ snapshots: content-type@1.0.5: {} + convert-gitmoji@0.1.5: {} + convert-source-map@2.0.0: {} cookie-es@1.2.2: {} @@ -17706,6 +17785,21 @@ snapshots: strip-final-newline: 4.0.0 yoctocolors: 2.1.1 + execa@9.5.2: + dependencies: + '@sindresorhus/merge-streams': 4.0.0 + cross-spawn: 7.0.6 + figures: 6.1.0 + get-stream: 9.0.1 + human-signals: 8.0.0 + is-plain-obj: 4.1.0 + is-stream: 4.0.1 + npm-run-path: 6.0.0 + pretty-ms: 9.2.0 + signal-exit: 4.1.0 + strip-final-newline: 4.0.0 + yoctocolors: 2.1.1 + expect-type@1.1.0: {} express@4.21.2: