From fca0df70dbbdc4468611eb68c2787bce923ba524 Mon Sep 17 00:00:00 2001 From: GZTime Date: Sun, 8 Sep 2024 11:17:33 +0800 Subject: [PATCH] chore(ci): update --- .github/workflows/ci.yml | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index daf71c99f..333975004 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -38,24 +38,6 @@ jobs: with: format: "YYYY-MM-DDTHH:mm:ssZ" - - name: Prebuild project - run: | - npm i -g pnpm - dotnet build "GZCTF.csproj" -c Release -o build - - - name: Publish project - run: | - dotnet publish "GZCTF.csproj" -c Release -o publish/linux/amd64 -r linux-x64 --no-self-contained /p:PublishReadyToRun=true - - # ignore arm64 for non-release tags - if [ "${{ env.RELEASE }}" = "true" ]; then - dotnet publish "GZCTF.csproj" -c Release -o publish/linux/arm64 -r linux-arm64 --no-self-contained /p:PublishReadyToRun=true - fi - env: - VITE_APP_BUILD_TIMESTAMP: ${{ steps.datetime.outputs.time }} - VITE_APP_GIT_SHA: ${{ github.sha }} - VITE_APP_GIT_NAME: ${{ github.ref_name }} - - name: Docker setup QEMU uses: docker/setup-qemu-action@v3 @@ -82,6 +64,24 @@ jobs: username: ${{ secrets.ALIYUN_USER }} password: ${{ secrets.ALIYUN_PASSWORD }} + - name: Prebuild project + run: | + npm i -g pnpm + dotnet build "GZCTF.csproj" -c Release -o build + + - name: Publish project + run: | + dotnet publish "GZCTF.csproj" -c Release -o publish/linux/amd64 -r linux-x64 --no-self-contained /p:PublishReadyToRun=true + + # ignore arm64 for non-release tags + if [ "${{ env.RELEASE }}" = "true" ]; then + dotnet publish "GZCTF.csproj" -c Release -o publish/linux/arm64 -r linux-arm64 --no-self-contained /p:PublishReadyToRun=true + fi + env: + VITE_APP_BUILD_TIMESTAMP: ${{ steps.datetime.outputs.time }} + VITE_APP_GIT_SHA: ${{ github.sha }} + VITE_APP_GIT_NAME: ${{ github.ref_name }} + - name: Docker metadata action uses: docker/metadata-action@v5 id: meta