From 8d43cb663543ec70bc26ab207641a0e04fd4ccf5 Mon Sep 17 00:00:00 2001 From: KunoiSayami Date: Sat, 11 Dec 2021 19:37:21 +0800 Subject: fix(ci): Fix workflow not process checkout Signed-off-by: KunoiSayami --- .github/workflows/aur-check-update.yml | 44 ++++++++++++++++++++++++++++++++++ .github/workflows/check-aur-update.yml | 39 ------------------------------ 2 files changed, 44 insertions(+), 39 deletions(-) create mode 100644 .github/workflows/aur-check-update.yml delete mode 100644 .github/workflows/check-aur-update.yml diff --git a/.github/workflows/aur-check-update.yml b/.github/workflows/aur-check-update.yml new file mode 100644 index 0000000..831e3a2 --- /dev/null +++ b/.github/workflows/aur-check-update.yml @@ -0,0 +1,44 @@ +name: AUR check update + +on: + schedule: + - cron: '19,49 * * * *' + push: + branches: + - master + + +jobs: + check-update: + runs-on: ubuntu-latest + strategy: + fail-fast: true + + name: Build + steps: + - uses: actions/checkout@v2 + - name: Set up base image + uses: 67au/check-aur-update-github-action@v0.1.0 + - name: Initialize submodules + shell: bash + run: | + git submodule update --init + - name: Check updates + shell: bash + run: | + ./utils/aur/check-aur-update.py --parse-pkgbuild ./utils/parse-pkgbuild.sh repo + - name: Set environments + id: get_env + shell: bash + run: | + echo "::set-output name=date::$(date +%Y%m%d%H%M)" + echo "::set-output name=body::$(git diff --name-only | sed -e 's|^repo/|* |')" + - name: Create Pull Request + uses: peter-evans/create-pull-request@v3 + with: + author: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> + commit-message: 'Auto update aur repository ${{ steps.get_env.outputs.date }}' + title: Update aur repository + delete-branch: true + branch: update/aur-${{ steps.get_env.outputs.date }} + body: "Update packages:\n${{ steps.get_env.outputs.body }}" diff --git a/.github/workflows/check-aur-update.yml b/.github/workflows/check-aur-update.yml deleted file mode 100644 index 9412fab..0000000 --- a/.github/workflows/check-aur-update.yml +++ /dev/null @@ -1,39 +0,0 @@ -name: Check aur updates - -on: - schedule: - - cron: '19,49 * * * *' - -jobs: - check-update: - runs-on: ubuntu-latest - strategy: - fail-fast: true - - name: Build - steps: - - name: Set up base image - uses: 67au/check-aur-update-github-action@v0.1.0 - - name: Initialize submodules - shell: bash - run: | - git submodule update --init - - name: Check updates - shell: bash - run: | - ./utils/aur/check-aur-update.py --parse-pkgbuild ./utils/parse-pkgbuild.sh repo - - name: Set environments - id: get_env - shell: bash - run: | - echo "::set-output name=date::$(date +%Y%m%d%H%M)" - echo "::set-output name=body::$(git diff --name-only | sed -e 's|^repo/|* |')" - - name: Create Pull Request - uses: peter-evans/create-pull-request@v3 - with: - author: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> - commit-message: 'Auto update aur repository ${{ steps.get_env.outputs.date }}' - title: Update aur repository - delete-branch: true - branch: update/aur-${{ steps.get_env.outputs.date }} - body: "Update packages:\n${{ steps.get_env.outputs.body }}" -- cgit v1.3.1