diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c7dddae90..fae0f968c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -107,7 +107,10 @@ jobs: - name: Install pnpm uses: pnpm/action-setup@008330803749db0355799c700092d9a85fd074e9 # v6.0.9 with: + cache: true + cache_dependency_path: web/pnpm-lock.yaml package_json_file: web/package.json + run_install: false - name: Build frontend working-directory: web @@ -115,6 +118,19 @@ jobs: pnpm install --ignore-scripts --frozen-lockfile pnpm build + - name: Build source code archive + run: tar --exclude='.github' --exclude-vcs --exclude-vcs-ignores --xform='s|^\./|defguard-${{ env.VERSION }}/|' --xz -cf ${{ runner.temp }}/defguard-${{ env.VERSION }}.tar.xz . + + - name: Upload source code archive + uses: shogo82148/actions-upload-release-asset@394b3c11c3cfc038b5396ad265c074065cf875c3 # v1.10.2 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ needs.create-release.outputs.upload_url }} + asset_path: ${{ runner.temp }}/defguard-${{ env.VERSION }}.tar.xz + asset_content_type: application/x-xz + overwrite: true + - name: Install Rust stable uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable with: diff --git a/.github/workflows/test-apt-repo.yml b/.github/workflows/test-apt-repo.yml index 0d58dc711..ccac6be80 100644 --- a/.github/workflows/test-apt-repo.yml +++ b/.github/workflows/test-apt-repo.yml @@ -74,7 +74,7 @@ jobs: -H "Authorization: Bearer $GH_TOKEN" \ https://api.github.com/repos/${{ matrix.github_repo }}/releases \ | jq -r --argjson pre "$PRERELEASE" --arg major "$MAJOR" \ - '[.[] | select(.prerelease == $pre and (.tag_name | startswith($major)))][0].tag_name // empty') + '[.[] | select(.draft == false and .prerelease == $pre and (.tag_name | startswith($major)))][0].tag_name // empty') if [ -z "$VERSION" ]; then echo "::notice::no $MAJOR release (prerelease=$PRERELEASE) of ${{ matrix.package }} on GitHub, skipping" echo "SKIP=true" >> $GITHUB_ENV