build: package the build in a flake and test with propogated timing #77
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json | |
name: Update dependencies | |
on: | |
pull_request: | |
permissions: | |
contents: write | |
pull-requests: write | |
jobs: | |
dependabot: | |
name: Merge automatic pull requests | |
runs-on: ubuntu-latest | |
if: github.actor == 'dependabot[bot]' | |
timeout-minutes: 12 | |
steps: | |
- name: Collect update metadata | |
id: metadata | |
uses: dependabot/fetch-metadata@v2 | |
with: | |
github-token: "${{ secrets.GITHUB_TOKEN }}" | |
- name: Wait for tests to succeed | |
uses: lewagon/wait-on-check-action@v1.3.4 | |
with: | |
check-name: "Inspect the code health" | |
ref: ${{ github.event.pull_request.head.sha }} | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
wait-interval: 10 | |
- name: Wait for a testing benchmark | |
uses: lewagon/wait-on-check-action@v1.3.4 | |
with: | |
check-name: "Monitor energy usage" | |
ref: ${{ github.event.pull_request.head.sha }} | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
wait-interval: 10 | |
allowed-conclusions: success | |
- name: Wait for packaging to pass | |
uses: lewagon/wait-on-check-action@v1.3.4 | |
with: | |
check-name: "Save a snapshot" | |
ref: ${{ github.event.pull_request.head.sha }} | |
repo-token: ${{ secrets.GITHUB_TOKEN }} | |
wait-interval: 10 | |
- name: Merge requests from the kind dependabot | |
if: steps.metadata.outputs.update-type == 'version-update:semver-patch' || steps.metadata.outputs.update-type == 'version-update:semver-minor' | |
run: gh pr merge --auto --squash "$PR_URL" | |
env: | |
PR_URL: ${{ github.event.pull_request.html_url }} | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} |