From abbdbafd69504b871ea41d8732ac42f5e7483185 Mon Sep 17 00:00:00 2001 From: Jeffery Date: Wed, 8 Apr 2026 09:08:08 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E4=BF=AE=E6=94=B9=20CD=20=E5=B7=A5?= =?UTF-8?q?=E4=BD=9C=E6=B5=81=E4=BD=BF=E7=94=A8=E7=9A=84=20action=20?= =?UTF-8?q?=E4=BE=86=E6=BA=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitea/workflows/master.yaml | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/.gitea/workflows/master.yaml b/.gitea/workflows/master.yaml index a2b9d6e..0eaf5c7 100644 --- a/.gitea/workflows/master.yaml +++ b/.gitea/workflows/master.yaml @@ -3,25 +3,27 @@ on: branches: - master jobs: - version: + calculate: name: "CD > 計算版本號" runs-on: ubuntu-latest - outputs: - version: ${{ steps.version.outputs.version }} steps: - name: 計算版本號 - id: version - uses: https://gitea.jsc.idv.tw/actions/calculate-version@${{ vars.ACTION_CALCULATE_VERSION }} - release: - name: "CD > 發布專案" + id: calculate + uses: https://gitea.housefun.com.tw/HP_TOOL/calculate-version-action@v${{ vars.CALCULATE_VERSION }} + with: + gitea-server: ${{ gitea.server_url }} + repository: ${{ gitea.repository }} + token: ${{ secrets.GITEA_TOKEN }} + outputs: + version: ${{ steps.calculate.outputs.VERSION }} + cd: + needs: [calculate] + name: "[CD] 發布專案" runs-on: ubuntu-latest - needs: version + env: + RUNNER_TOOL_CACHE: /toolcache steps: - name: 發布專案 - uses: akkuman/gitea-release-action@${{ vars.ACTION_RELEASE_VERSION }} + uses: akkuman/gitea-release-action@v1 with: - tag_name: "v${{ needs.version.outputs.version }}" - - name: 清理成品 - uses: https://gitea.jsc.idv.tw/actions/cleanup-release@${{ vars.ACTION_CLEANUP_RELEASE_VERSION }} - with: - RUNNER_TOKEN: ${{ secrets.RUNNER_TOKEN }} \ No newline at end of file + tag_name: "v${{ needs.calculate.outputs.version }}" \ No newline at end of file