From 595079e5ed94b5213bccddecc7796efddde61325 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Francisco=20Jos=C3=A9=20Garc=C3=ADa=20Garc=C3=ADa?= Date: Wed, 26 May 2021 10:00:06 +0200 Subject: [PATCH] Upload as release artifacts Also change build triggers to manual, pull_request and cron every 6 hours --- .github/workflows/build.yml | 37 ++++++++++++++++++++++++++++++++----- 1 file changed, 32 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index c4bb420f..3418e37b 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,12 +1,10 @@ name: Packages on: - push: - branches: - - master + workflow_dispatch: pull_request: schedule: - - cron: "0 0 * * *" + - cron: "0 */6 * * *" repository_dispatch: types: [run_build] @@ -54,6 +52,21 @@ jobs: with: name: package path: ${{ matrix.package }}/*-arm.tar.xz + - name: Rename release artifacts + if: contains(github.ref,'refs/heads/master') + run: | + cd ${{ matrix.package }} + export FILE=`echo *-arm.tar.xz` + mv $FILE ${{ matrix.package }}.tar.xz + - uses: svenstaro/upload-release-action@v2 + if: contains(github.ref,'refs/heads/master') + with: + repo_token: ${{ secrets.GITHUB_TOKEN }} + file: ${{ matrix.package }}/*.tar.xz + overwrite: true + file_glob: true + tag: ${{ github.ref }} + release_name: master build_depends: needs: [prepare_jobs, build] runs-on: ubuntu-18.04 @@ -94,4 +107,18 @@ jobs: with: name: package path: ${{ env.PACKAGE }}/*-arm.tar.xz - + - name: Rename release artifacts + if: contains(github.ref,'refs/heads/master') + run: | + cd ${{ env.PACKAGE }} + export FILE=`echo *-arm.tar.xz` + mv $FILE ${{ env.PACKAGE }}.tar.xz + - uses: svenstaro/upload-release-action@v2 + if: contains(github.ref,'refs/heads/master') + with: + repo_token: ${{ secrets.GITHUB_TOKEN }} + file: ${{ env.PACKAGE }}/*.tar.xz + overwrite: true + file_glob: true + tag: ${{ github.ref }} + release_name: master