Skip to content

Commit

Permalink
Update reusable action to update flake.lock
Browse files Browse the repository at this point in the history
Closes #165
Closes #162
Closes #160
Closes #157
  • Loading branch information
kachick committed Feb 9, 2024
1 parent 4817ed2 commit bda966b
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 6 deletions.
20 changes: 15 additions & 5 deletions .github/workflows/merge-bot-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,28 @@ jobs:
- name: Dependabot metadata
id: metadata
uses: dependabot/fetch-metadata@v1.6.0
with:
github-token: '${{ secrets.GITHUB_TOKEN }}'
- uses: actions/checkout@v4
- name: Wait other jobs
if: ${{steps.metadata.outputs.update-type != 'version-update:semver-major'}}
uses: kachick/wait-other-jobs@v2
timeout-minutes: 10
with:
github-token: '${{ secrets.GITHUB_TOKEN }}'
- name: Approve and merge
if: ${{steps.metadata.outputs.update-type != 'version-update:semver-major'}}
run: gh pr review --approve "$PR_URL" && gh pr merge --auto --squash "$PR_URL"
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 }}
2 changes: 1 addition & 1 deletion .github/workflows/update-nixpkgs-and-versions-in-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:

jobs:
update-nixpkgs:
uses: kachick/anylang-template/.github/workflows/reusable-update-nixpkgs-and-versions-in-ci.yml@2413fce002263e6675ce084da251be0dbbe2a8fc
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' }}
Expand Down

0 comments on commit bda966b

Please sign in to comment.