diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4c499e9..b4f2952 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -15,13 +15,13 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Generate matrix id: gen-matrix run: | JOBS="$(./generate_device_recipe.py --matrix)" - echo ::set-output name=matrix::${JOBS} + echo "matrix=${JOBS}" >> $GITHUB_OUTPUT build: runs-on: ubuntu-20.04 @@ -53,7 +53,7 @@ jobs: run: echo "DROIDIAN_IDENTIFIER=${{ matrix.config.product }}-${{ matrix.config.arch }}-${{ matrix.config.edition }}-${{ matrix.config.variant }}-${{ matrix.config.apilevel }}" >> $GITHUB_ENV - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 with: lfs: 'true' submodules: 'recursive' @@ -62,7 +62,7 @@ jobs: run: git submodule update --init --recursive - name: QEMU set-up - uses: docker/setup-qemu-action@v1 + uses: docker/setup-qemu-action@v3 - name: Create build dir run: mkdir -p /tmp/buildd-results @@ -78,7 +78,7 @@ jobs: docker exec $CONTAINER_HASH /bin/sh -c 'cd /buildd/sources; DROIDIAN_VERSION="${{ env.DROIDIAN_VERSION }}" ./generate_device_recipe.py ${{ matrix.config.product }} ${{ matrix.config.arch }} ${{ matrix.config.edition }} ${{ matrix.config.variant }} ${{ matrix.config.apilevel }} && debos --disable-fakemachine generated/droidian.yaml' - name: Upload artifacts - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: droidian-out-${{ matrix.config.product }}-${{ matrix.config.arch }}-${{ matrix.config.edition }}-${{ matrix.config.variant }}-${{ matrix.config.apilevel }} path: out/* @@ -93,6 +93,9 @@ jobs: upload_url: ${{ steps.create_release.outputs.upload_url }}${{ steps.create_nightly.outputs.upload_url }} steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Free up some storage uses: jlumbroso/free-disk-space@main with: @@ -103,24 +106,17 @@ jobs: large-packages: true swap-storage: true - - name: Delete old nightly release - uses: dev-drprasad/delete-tag-and-release@v0.2.1 - if: startsWith(github.ref, 'refs/tags/droidian') != true - with: - delete_release: true # default: false - tag_name: nightly # tag name to delete + - name: Nightly tag env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - - - name: Tag snapshot if: startsWith(github.ref, 'refs/tags/droidian') != true - uses: tvdias/github-tagger@v0.0.1 - with: - repo-token: ${{ secrets.GITHUB_TOKEN }} - tag: nightly + run: | + gh release delete nightly --yes | true + git push --delete origin refs/tags/nightly || true + gh release create nightly - name: Download artifacts - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: path: droidian-out @@ -136,7 +132,7 @@ jobs: - name: Create stable release (drafted) id: create_release if: startsWith(github.ref, 'refs/tags/droidian') - uses: softprops/action-gh-release@v1 + uses: softprops/action-gh-release@v2 with: files: droidian-out/SHA256SUMS tag_name: ${{ github.ref }} @@ -146,7 +142,7 @@ jobs: - name: Create nightly release id: create_nightly if: startsWith(github.ref, 'refs/tags/droidian') != true - uses: softprops/action-gh-release@v1 + uses: softprops/action-gh-release@v2 with: files: droidian-out/SHA256SUMS tag_name: nightly @@ -168,7 +164,7 @@ jobs: steps: - name: Download artifacts - uses: actions/download-artifact@v3 + uses: actions/download-artifact@v4 with: name: droidian-out-${{ matrix.config.product }}-${{ matrix.config.arch }}-${{ matrix.config.edition }}-${{ matrix.config.variant }}-${{ matrix.config.apilevel }} path: droidian-out @@ -176,7 +172,7 @@ jobs: - name: Create stable release (drafted) id: create_release if: startsWith(github.ref, 'refs/tags/droidian') - uses: softprops/action-gh-release@v1 + uses: softprops/action-gh-release@v2 with: files: droidian-out/* tag_name: ${{ github.ref }} @@ -186,7 +182,7 @@ jobs: - name: Create nightly release id: create_nightly if: startsWith(github.ref, 'refs/tags/droidian') != true - uses: softprops/action-gh-release@v1 + uses: softprops/action-gh-release@v2 with: files: droidian-out/* tag_name: nightly