From f4ea014b3c820b357d18a5ce52d0ae2e56c56229 Mon Sep 17 00:00:00 2001 From: Wu Clan Date: Mon, 24 Feb 2025 18:31:02 +0800 Subject: [PATCH 1/4] Update changelog ci for github action --- .github/workflows/changelog.yml | 34 ++++++++++++--------------------- docs/changelog.md | 22 --------------------- 2 files changed, 12 insertions(+), 44 deletions(-) diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index f82eee7..f855061 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -1,31 +1,21 @@ -name: Change Logs +name: Release changelog on: - release: - types: [ released ] + push: + tags: + - v* + pull_request: jobs: - latest-changes: + changelog: runs-on: ubuntu-latest permissions: 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: - release-notes: ${{ github.event.release.body }} - latest-version: ${{ github.event.release.tag_name }} - path-to-changelog: docs/changelog.md - - - name: Commit updated CHANGELOG - uses: stefanzweifel/git-auto-commit-action@v5 + - uses: TriPSs/conventional-changelog-action@v5 with: - branch: ${{ github.event.release.target_commitish }} - commit_message: 📝 Update release notes - file_pattern: docs/changelog.md + github-token: ${{ secrets.github_token }} + git-message: '📝 Update release notes' + git-user-name: 'github-actions[bot]' + git-user-email: 'github-actions[bot]@users.noreply.github.com' + output-file: docs/changelog.md diff --git a/docs/changelog.md b/docs/changelog.md index 7c93918..e69de29 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,22 +0,0 @@ -# Change Logs - -## 1.6.0 - 2024-11-09 - -### What's Changed - -* Add the flush usage by @wu-clan in https://github.com/fastapi-practices/sqlalchemy-crud-plus/pull/32 -* Prepare for 1.6.0 release by @wu-clan in https://github.com/fastapi-practices/sqlalchemy-crud-plus/pull/33 - -**Full Changelog**: https://github.com/fastapi-practices/sqlalchemy-crud-plus/compare/1.5.0...1.6.0 - -## 1.5.0 - 2024-11-03 - -### What's Changed - -* Update some usage documents by @wu-clan in https://github.com/fastapi-practices/sqlalchemy-crud-plus/pull/27 -* Update the interactive link address by @wu-clan in https://github.com/fastapi-practices/sqlalchemy-crud-plus/pull/28 -* update interactive link descriptions by @wu-clan in https://github.com/fastapi-practices/sqlalchemy-crud-plus/pull/29 -* Update package manager pdm to uv by @wu-clan in https://github.com/fastapi-practices/sqlalchemy-crud-plus/pull/31 -* Add create and update kwargs usage by @wu-clan in https://github.com/fastapi-practices/sqlalchemy-crud-plus/pull/30 - -**Full Changelog**: https://github.com/fastapi-practices/sqlalchemy-crud-plus/compare/1.4.0...1.5.0 From ebbab21624750e104451a9ada7f69cbf9743392d Mon Sep 17 00:00:00 2001 From: Wu Clan Date: Mon, 24 Feb 2025 18:36:43 +0800 Subject: [PATCH 2/4] Fix steps --- .github/workflows/changelog.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index f855061..a38c722 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -12,6 +12,9 @@ jobs: permissions: contents: write steps: + - name: Checkout code + uses: actions/checkout@v4 + - uses: TriPSs/conventional-changelog-action@v5 with: github-token: ${{ secrets.github_token }} From 13d93c95c25aa9e4c4721f64b446588c57944494 Mon Sep 17 00:00:00 2001 From: Wu Clan Date: Mon, 24 Feb 2025 18:39:52 +0800 Subject: [PATCH 3/4] update branch --- .github/workflows/changelog.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index a38c722..14d5e0f 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -21,4 +21,5 @@ jobs: git-message: '📝 Update release notes' git-user-name: 'github-actions[bot]' git-user-email: 'github-actions[bot]@users.noreply.github.com' - output-file: docs/changelog.md + git-branch: 'master' + output-file: 'docs/changelog.md' From aee87b702f933abd2b2b0c27b552e986dcc072ea Mon Sep 17 00:00:00 2001 From: Wu Clan Date: Mon, 24 Feb 2025 18:50:36 +0800 Subject: [PATCH 4/4] update on --- .github/workflows/changelog.yml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index 14d5e0f..be65e19 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -2,9 +2,6 @@ name: Release changelog on: push: - tags: - - v* - pull_request: jobs: changelog: @@ -21,5 +18,4 @@ jobs: git-message: '📝 Update release notes' git-user-name: 'github-actions[bot]' git-user-email: 'github-actions[bot]@users.noreply.github.com' - git-branch: 'master' output-file: 'docs/changelog.md'