-
Notifications
You must be signed in to change notification settings - Fork 2
42 lines (39 loc) · 1.42 KB
/
nixpkgs-review.yaml
File metadata and controls
42 lines (39 loc) · 1.42 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
---
name: Nixpkgs Review
on:
workflow_dispatch:
inputs:
pr:
description: "The number of the pull request to review."
type: number
required: true
run-name: "Review Nixpkgs PR ${{ inputs.pr }} with nixpkgs-review"
jobs:
review:
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v5
with:
repository: "NixOS/nixpkgs"
fetch-depth:
# Infinite depth (source: https://git-scm.com/docs/shallow)
2147483647
- uses: wimpysworld/nothing-but-nix@10c936d9e46521bf923f75458e0cbd4fa309300d
with:
hatchet-protocol: "carve"
- uses: cachix/install-nix-action@v31
with:
github_access_token: ${{ secrets.GITHUB_TOKEN }}
- name: Configure committer identity
run: |
git config user.email "github-actions[bot]@users.noreply.github.com"
git config user.name "github-actions[bot]"
- name: Run nixpkgs-review
env:
NIXPKGS_REVIEW_ATTR: "github:${{ github.repository }}/${{ github.sha }}#nixpkgs-review"
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
RUN_COMMAND: >-
find logs/ -type f -exec awk 'FNR==1{print FILENAME}1' {} +;
cat report.md >> $GITHUB_STEP_SUMMARY;
jq -e '.failed == []' < report.json
run: nix run "${{ env.NIXPKGS_REVIEW_ATTR }}" -- pr ${{ inputs.pr }} --run "${{ env.RUN_COMMAND }}"