Skip to content

Commit

Permalink
Github eval to its own workflow
Browse files Browse the repository at this point in the history
Signed-off-by: Henri Rosten <[email protected]>
  • Loading branch information
henrirosten authored and brianmcgillion committed Jan 31, 2025
1 parent 8efb45d commit f1aa57f
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
run: nix fmt -- --fail-on-change
- name: Check reuse lint
run: nix develop --command reuse lint
- name: Check ghaf flake evaluates
- name: Check nix flake show runs successfully
run: nix flake show --all-systems
- name: Check templates
run: |
Expand Down
45 changes: 45 additions & 0 deletions .github/workflows/eval.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# SPDX-FileCopyrightText: 2022-2025 TII (SSRC) and the Ghaf contributors
#
# SPDX-License-Identifier: Apache-2.0

name: eval
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
eval:
runs-on: ubuntu-latest
timeout-minutes: 360
strategy:
matrix:
include:
- jobid: 0
- jobid: 1
- jobid: 2
- jobid: 3
- jobid: 4
- jobid: 5
- jobid: 6
- jobid: 7
concurrency:
# Cancel any in-progress workflow runs from the same PR or branch,
# allowing matrix jobs to run concurrently:
group: ${{ github.workflow }}.${{ github.event.pull_request.number || github.ref }}.${{ matrix.jobid }}
cancel-in-progress: true
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: ${{ github.event.pull_request.merge.sha || github.ref }}
fetch-depth: 0
- name: Install nix
uses: cachix/install-nix-action@v30
- name: Evaluate (jobid=${{ matrix.jobid }})
run: |
echo "strategy.job-total: ${{ strategy.job-total }}"
echo "matrix.jobid: ${{ matrix.jobid }}"
nix develop --command .github/eval.sh -j ${{ matrix.jobid }} -m ${{ strategy.job-total }}

0 comments on commit f1aa57f

Please sign in to comment.