From 0c1391b78adc194f0cf3c8a7ca497b51ac55f0f4 Mon Sep 17 00:00:00 2001 From: Kenichi Kamiya Date: Fri, 9 Feb 2024 12:40:33 +0900 Subject: [PATCH] Update reusable action to update flake.lock --- .github/workflows/merge-bot-pr.yml | 15 +++++++++++++++ .github/workflows/update-flake-lock-and-ci.yml | 2 +- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/.github/workflows/merge-bot-pr.yml b/.github/workflows/merge-bot-pr.yml index 202d930..7ef25c8 100644 --- a/.github/workflows/merge-bot-pr.yml +++ b/.github/workflows/merge-bot-pr.yml @@ -46,3 +46,18 @@ jobs: env: PR_URL: ${{github.event.pull_request.html_url}} GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} + + # https://github.com/kachick/anylang-template/issues/51 + selfup-runner: + timeout-minutes: 30 + runs-on: ubuntu-latest + if: ${{ github.actor == 'selfup-runner[bot]' }} + steps: + - name: Wait other jobs + uses: kachick/wait-other-jobs@v2 + timeout-minutes: 20 + - name: Approve and merge + run: gh pr review --approve "$PR_URL" && gh pr merge --auto --delete-branch --squash "$PR_URL" + env: + PR_URL: ${{ github.event.pull_request.html_url }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/update-flake-lock-and-ci.yml b/.github/workflows/update-flake-lock-and-ci.yml index 63f6582..1f6ae52 100644 --- a/.github/workflows/update-flake-lock-and-ci.yml +++ b/.github/workflows/update-flake-lock-and-ci.yml @@ -11,7 +11,7 @@ on: jobs: update-nixpkgs: - uses: kachick/anylang-template/.github/workflows/reusable-update-nixpkgs-and-versions-in-ci.yml@b267dd151327488f5cf15d9f2b273f4ece1da401 + uses: kachick/selfup/.github/workflows/reusable-bump-flake-lock-and-selfup.yml@action-v1 if: (github.event.sender.login == 'kachick') || (github.event_name != 'pull_request') with: dry-run: ${{ github.event_name == 'pull_request' }}