chore(工作流程): 重構 CI 與 master 流程改用 gitea release 與 commit tag
CI / 1. BUILD (pull_request) Successful in 2s
CI / 2. TEST (pull_request) Successful in 36s
CI / 3. RESULT (pull_request) Successful in 1s

This commit is contained in:
Jeffery
2026-07-02 14:26:25 +08:00
parent 1e7be78e97
commit b73feec9da
2 changed files with 30 additions and 36 deletions
+10 -19
View File
@@ -4,27 +4,18 @@ on:
branches:
- master
jobs:
build:
name: 1. BUILD
runs-on: ubuntu
outputs:
version: ${{ steps.calculate-version.outputs.version }}
steps:
- name: Calculate Version
id: calculate-version
env:
VERSION: 0.0.1
run: echo "version=$VERSION" >> "$GITHUB_OUTPUT"
deploy:
name: 2. DEPLOY
name: DEPLOY
runs-on: ubuntu
needs: [build]
env:
VERSION: ${{ needs.build.outputs.version }}
COMMIT_SHA: ${{ gitea.event.commits[1].id }}
steps:
- name: Publishing Release
uses: akkuman/gitea-release-action@${{ vars.ACTION_GITEA_RELEASE_VERSION }}
- name: Source Code Checkout
uses: actions/checkout@${{ vars.ACTION_CHECKOUT_VERSION }}
with:
name: "${{ gitea.event.repository.name }} v${{ env.VERSION }}"
tag_name: "v${{ env.VERSION }}"
target_commitish: ${{ gitea.sha }}
fetch-depth: 0
- name: Get Commit Tag
id: commit
run: echo "tag=$(git describe --contains ${{ env.COMMIT_SHA }})" >> $GITEA_OUTPUT
- name: Show Tag
run: echo "${{ steps.commit.outputs.tag }}"