-
Notifications
You must be signed in to change notification settings - Fork 1
37 lines (35 loc) · 898 Bytes
/
deadnix.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
name: Fix dead code with deadnix
on:
push:
paths:
- "**.nix"
workflow_dispatch:
jobs:
deadnix:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Check Out Repository
uses: actions/checkout@v4
- name: Set Up Nix
uses: cachix/install-nix-action@master
with:
nix_path: nixpkgs=channel:nixos-unstable
- name: Run deadnix check
uses: workflow/nix-shell-action@main
continue-on-error: true
with:
packages: deadnix
script: |
deadnix
- name: Run deadnix fix
uses: workflow/nix-shell-action@main
with:
packages: deadnix
script: |
deadnix -e
- name: Push changes
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "Fix dead code using deadnix"