From 01f23f598846e47e231f24ba2cf54bd31e8c084c Mon Sep 17 00:00:00 2001 From: Jonas Ha Date: Sun, 9 Nov 2025 15:24:09 -0500 Subject: [PATCH 1/4] chore(ci): update workflows for .NET and actions versions - Bump `checkout` action from v4 to v5. - Bump `setup-dotnet` action from v4 to v5. - Remove matrix strategy for .NET versions, hardcoding to 10.0.x. --- .github/workflows/publish-to-nuget.yaml | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/.github/workflows/publish-to-nuget.yaml b/.github/workflows/publish-to-nuget.yaml index d69b7b56..7e8b8dd5 100644 --- a/.github/workflows/publish-to-nuget.yaml +++ b/.github/workflows/publish-to-nuget.yaml @@ -9,18 +9,16 @@ jobs: runs-on: ubuntu-latest permissions: contents: read - strategy: - matrix: - dotnet-version: ['8.0', '9.0', '10.0'] + steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 with: fetch-depth: 0 - name: Setup .NET - uses: actions/setup-dotnet@v4 + uses: actions/setup-dotnet@v5 with: - dotnet-version: ${{ matrix.dotnet-version }} + dotnet-version: 10.0.x - name: Restore dependencies run: dotnet restore From 7b4050d7cdc41aa5d6e4151af47c8395295d226d Mon Sep 17 00:00:00 2001 From: Jonas Ha Date: Sun, 9 Nov 2025 18:32:07 -0500 Subject: [PATCH 2/4] docs: add CHANGELOG.md following Keep a Changelog format - Document notable changes in a standardized changelog file. - Reference Keep a Changelog and Semantic Versioning guidelines. --- CHANGELOG.md | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 00000000..3a919b38 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,7 @@ +# Changelog + +All notable changes to this project will be documented in this file. + +The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), +and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). + From 482a5ebc498fe38b3400cd2c27d36c3a17dcd5d9 Mon Sep 17 00:00:00 2001 From: Jonas Ha Date: Sun, 9 Nov 2025 18:33:25 -0500 Subject: [PATCH 3/4] docs: remove unnecessary contents from CHANGELOG.md - Clean up unnecessary information and links from CHANGELOG.md. - Simplify file to keep only the essential content. --- CHANGELOG.md | 6 ------ 1 file changed, 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3a919b38..825c32f0 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,7 +1 @@ # Changelog - -All notable changes to this project will be documented in this file. - -The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), -and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). - From 6fd96ad51ad921e315a1a556a62f5b50f0a9784e Mon Sep 17 00:00:00 2001 From: Jonas Ha Date: Sun, 9 Nov 2025 18:35:34 -0500 Subject: [PATCH 4/4] chore(ci): replace release notes workflow with changelog updater - Remove `generate-release-notes.yaml` in favor of `update-changelog.yaml`. - Use `stefanzweifel/changelog-updater-action` for managing CHANGELOG updates. - Simplify and streamline the changelog update process in CI workflows. --- .github/workflows/generate-release-notes.yaml | 96 ------------------- .github/workflows/update-changelog.yaml | 34 +++++++ 2 files changed, 34 insertions(+), 96 deletions(-) delete mode 100644 .github/workflows/generate-release-notes.yaml create mode 100644 .github/workflows/update-changelog.yaml diff --git a/.github/workflows/generate-release-notes.yaml b/.github/workflows/generate-release-notes.yaml deleted file mode 100644 index 7352c5cb..00000000 --- a/.github/workflows/generate-release-notes.yaml +++ /dev/null @@ -1,96 +0,0 @@ -name: Generate Release Notes - -on: - release: - types: [published] - -jobs: - generate-release-notes: - runs-on: ubuntu-latest - permissions: - contents: write - pull-requests: read - steps: - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: '20' - cache: 'npm' - - - name: Install GREN - run: npm install -g github-release-notes - - - name: Generate release notes - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: | - gren release --token=$GITHUB_TOKEN \ - --data-source=prs \ - --prefix=v \ - --tags=${{ github.event.release.tag_name }} \ - --changelog=true \ - --updateChangelog=true - - - name: Commit CHANGELOG.md - continue-on-error: true - run: | - git config user.name "github-actions[bot]" - git config user.email "github-actions[bot]@users.noreply.github.com" - - if git diff --quiet CHANGELOG.md; then - echo "No changes to CHANGELOG.md" - else - git add CHANGELOG.md - git commit -m "docs: update CHANGELOG for ${{ github.event.release.tag_name }}" - git push - fi - - - name: Update release notes on GitHub - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: | - # Extract release notes from generated file - RELEASE_ID=${{ github.event.release.id }} - TAG=${{ github.event.release.tag_name }} - - # Get the generated notes (GREN creates them in release description) - echo "Release notes generation complete for $TAG" - echo "See CHANGELOG.md for the full changelog" - - update-changelog: - runs-on: ubuntu-latest - if: github.event_name == 'release' && github.event.action == 'published' - permissions: - contents: write - steps: - - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - - name: Setup Node.js - uses: actions/setup-node@v4 - with: - node-version: '20' - - - name: Install GREN - run: npm install -g github-release-notes - - - name: Update changelog only - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - run: | - gren changelog --update --token=$GITHUB_TOKEN --data-source=prs || true - - - name: Commit updated changelog - continue-on-error: true - run: | - git config user.name "github-actions[bot]" - git config user.email "github-actions[bot]@users.noreply.github.com" - - git add CHANGELOG.md || true - git commit -m "docs: update CHANGELOG for release ${{ github.event.release.tag_name }}" || true - git push || true diff --git a/.github/workflows/update-changelog.yaml b/.github/workflows/update-changelog.yaml new file mode 100644 index 00000000..62c55419 --- /dev/null +++ b/.github/workflows/update-changelog.yaml @@ -0,0 +1,34 @@ +name: "Update Changelog" + +on: + release: + types: [released] + +jobs: + update: + runs-on: ubuntu-latest + + permissions: + # Give the default GITHUB_TOKEN write permission to commit and push the + # updated CHANGELOG back to the repository. + # https://github.blog/changelog/2023-02-02-github-actions-updating-the-default-github_token-permissions-to-read-only/ + contents: write + + steps: + - name: Checkout code + uses: actions/checkout@v4 + with: + ref: ${{ github.event.release.target_commitish }} + + - name: Update Changelog + uses: stefanzweifel/changelog-updater-action@v1 + with: + latest-version: ${{ github.event.release.tag_name }} + release-notes: ${{ github.event.release.body }} + + - name: Commit updated CHANGELOG + uses: stefanzweifel/git-auto-commit-action@v5 + with: + branch: ${{ github.event.release.target_commitish }} + commit_message: Update CHANGELOG + file_pattern: CHANGELOG.md \ No newline at end of file