summaryrefslogtreecommitdiff
path: root/.github/workflows/ci.yaml
blob: edbf0176638b0fc5ad96fa1e5e0f1984f40ff9e5 (plain)
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
name: CI

on:
  push:
    branches: [main]
  workflow_dispatch:

jobs:
  test:
    name: Run test (with `${{ matrix.sources }}`)

    runs-on: ubuntu-latest

    strategy:
      matrix:
        sources: ["", "nixpkgs nixos-24.05"]

    permissions:
      contents: write 
      pull-requests: write

    steps:
      - name: Checkout repository
        uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6

      - name: Install Nix
        uses: cachix/install-nix-action@ba0dd844c9180cbf77aa72a116d6fbc515d0e87b # v27

      - name: Install npins
        run: |
          nix profile install 'nixpkgs#npins'

      - name: Update npins sources
        uses: ./.
        with:
          sources: "nixpkgs"
          npins-directory: ./test/npins
          commit-message: "test: update npins sources"