-
Notifications
You must be signed in to change notification settings - Fork 0
58 lines (51 loc) · 1.44 KB
/
check.yml
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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# SPDX-FileCopyrightText: Andrew Hayzen <[email protected]>
#
# SPDX-License-Identifier: MPL-2.0
name: check
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
jobs:
license-check:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- name: REUSE Compliance Check
uses: fsfe/reuse-action@v3
flake-checker:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/flake-checker-action@v5
nix-fmt:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@v10
- uses: DeterminateSystems/magic-nix-cache-action@v4
- name: nix fmt
run: nix fmt
- name: git diff
run: git diff --exit-code
shellcheck:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
# Shellcheck should already be installed on github runners
- name: install shellcheck
run: sudo apt install --yes shellcheck
- name: shellcheck scripts/*.sh
run: shellcheck myscripts/*.sh
nix-flake-check:
# Run after pre checks
needs: [license-check, flake-checker, nix-fmt]
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
- uses: DeterminateSystems/nix-installer-action@v10
- uses: DeterminateSystems/magic-nix-cache-action@v4
- name: nix flake check
run: nix flake --option sandbox false check -L