From 1c3d52d6f2f13a8194a69121000800cc8ae9c619 Mon Sep 17 00:00:00 2001 From: Kieron Lanning Date: Sun, 24 May 2026 17:13:46 +0100 Subject: [PATCH 1/3] chore: remove husky No git hooks needed - actionlint runs in CI via the validate-workflows job. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- package.json | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/package.json b/package.json index 8110f4bf..2a58163a 100644 --- a/package.json +++ b/package.json @@ -1,24 +1,24 @@ { - "name": "purview-telemetry-sourcegenerator", - "version": "4.2.0", - "description": "Generates [`ActivitySource`](https://learn.microsoft.com/en-us/dotnet/api/system.diagnostics.activitysource), [`ILogger`](https://learn.microsoft.com/en-us/dotnet/api/microsoft.extensions.logging.ilogger), and [`Metrics`](https://learn.microsoft.com/en-us/dotnet/api/system.diagnostics.metrics) based on interface methods.", - "readme": "README.md", - "scripts": { - "changeset": "changeset", - "version-packages": "changeset version && bun .build/update-version.ts" - }, - "repository": { - "type": "git", - "url": "git+https://github.com/kjldev/purview-telemetry-sourcegenerator.git" - }, - "author": "Kieron Lanning (https://github.com/kieronlanning/)", - "license": "ISC", - "bugs": { - "url": "https://github.com/kjldev/purview-telemetry-sourcegenerator/issues" - }, - "homepage": "https://github.com/kjldev/purview-telemetry-sourcegenerator#readme", - "devDependencies": { - "@changesets/changelog-github": "^0.5.0", - "@changesets/cli": "^2.27.12" - } + "name": "purview-telemetry-sourcegenerator", + "version": "4.2.0", + "description": "Generates [`ActivitySource`](https://learn.microsoft.com/en-us/dotnet/api/system.diagnostics.activitysource), [`ILogger`](https://learn.microsoft.com/en-us/dotnet/api/microsoft.extensions.logging.ilogger), and [`Metrics`](https://learn.microsoft.com/en-us/dotnet/api/system.diagnostics.metrics) based on interface methods.", + "readme": "README.md", + "scripts": { + "changeset": "changeset", + "version-packages": "changeset version && bun .build/update-version.ts" + }, + "repository": { + "type": "git", + "url": "git+https://github.com/kjldev/purview-telemetry-sourcegenerator.git" + }, + "author": "Kieron Lanning (https://github.com/kieronlanning/)", + "license": "ISC", + "bugs": { + "url": "https://github.com/kjldev/purview-telemetry-sourcegenerator/issues" + }, + "homepage": "https://github.com/kjldev/purview-telemetry-sourcegenerator#readme", + "devDependencies": { + "@changesets/changelog-github": "^0.5.0", + "@changesets/cli": "^2.27.12" + } } From 8d6a6dd045a7d53b98fd8164a4507ffe2cdbd9b1 Mon Sep 17 00:00:00 2001 From: Kieron Lanning Date: Sun, 24 May 2026 17:15:53 +0100 Subject: [PATCH 2/3] chore(deps): bump actions to Node.js 24 compatible versions actions/checkout: v4 -> v6 actions/setup-dotnet: v4 -> v5 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .github/workflows/cd.yml | 4 ++-- .github/workflows/ci.yml | 12 ++++++------ 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index f57ba1ed..687840c2 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -25,7 +25,7 @@ jobs: steps: - name: Checkout code - uses: actions/checkout@v4 + uses: actions/checkout@v6 with: fetch-depth: 0 @@ -63,7 +63,7 @@ jobs: - name: Set up .NET if: ${{ steps.release-check.outputs.should_release == 'true' }} - uses: actions/setup-dotnet@v4 + uses: actions/setup-dotnet@v5 with: global-json-file: ./global.json diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 732f5add..e2f4da52 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -15,10 +15,10 @@ jobs: steps: - name: Checkout code - uses: actions/checkout@v4 + uses: actions/checkout@v6 - name: Set up .NET - uses: actions/setup-dotnet@v4 + uses: actions/setup-dotnet@v5 with: global-json-file: ./global.json @@ -38,10 +38,10 @@ jobs: steps: - name: Checkout code - uses: actions/checkout@v4 + uses: actions/checkout@v6 - name: Set up .NET - uses: actions/setup-dotnet@v4 + uses: actions/setup-dotnet@v5 with: global-json-file: ./src/global.json @@ -64,10 +64,10 @@ jobs: steps: - name: Checkout code - uses: actions/checkout@v4 + uses: actions/checkout@v6 - name: Set up .NET - uses: actions/setup-dotnet@v4 + uses: actions/setup-dotnet@v5 with: global-json-file: ./samples/SampleApp/global.json From d7cea1d6149d03bca2012f2e255d77e659425b90 Mon Sep 17 00:00:00 2001 From: Kieron Lanning Date: Sun, 24 May 2026 17:23:35 +0100 Subject: [PATCH 3/3] fix(release): skip wiki push during version PR, move to CD post-release update-version.ts skips pullWiki/pushWiki when GITHUB_ACTIONS is set. cd.yml gains post-release Update wiki step using GITHUB_TOKEN. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .build/update-version.ts | 12 ++++++++++-- .github/workflows/cd.yml | 22 ++++++++++++++++++++++ 2 files changed, 32 insertions(+), 2 deletions(-) diff --git a/.build/update-version.ts b/.build/update-version.ts index 77e31d53..a4d60535 100644 --- a/.build/update-version.ts +++ b/.build/update-version.ts @@ -147,6 +147,14 @@ function pushWiki() { } // --- Main --- -pullWiki(); +// When running in CI (changeset version PR creation), skip the wiki push. +// The wiki is updated post-release in the CD pipeline instead. +const isCI = !!process.env.GITHUB_ACTIONS; + +if (!isCI) { + pullWiki(); +} updateFilesVersion(); -pushWiki(); +if (!isCI) { + pushWiki(); +} diff --git a/.github/workflows/cd.yml b/.github/workflows/cd.yml index 687840c2..133a7247 100644 --- a/.github/workflows/cd.yml +++ b/.github/workflows/cd.yml @@ -163,3 +163,25 @@ jobs: if: ${{ steps.release-check.outputs.should_release != 'true' }} run: echo "Release ${{ steps.version.outputs.tag }} already exists — skipping." + - name: Set up Bun + if: ${{ steps.release-check.outputs.should_release == 'true' }} + uses: oven-sh/setup-bun@v2 + + - name: Install dependencies + if: ${{ steps.release-check.outputs.should_release == 'true' }} + run: bun install + + - name: Update wiki + if: ${{ steps.release-check.outputs.should_release == 'true' }} + env: + GH_TOKEN: ${{ github.token }} + shell: bash + run: | + set -euo pipefail + + git config --global user.email "github-actions[bot]@users.noreply.github.com" + git config --global user.name "github-actions[bot]" + git config --global url."https://x-access-token:${GH_TOKEN}@github.com/".insteadOf "https://github.com/" + + bun .build/update-version.ts +