-
Notifications
You must be signed in to change notification settings - Fork 0
45 lines (39 loc) · 1.36 KB
/
nvidia.yaml
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
name: Build NVIDIA stuff every day at 3:00
on:
workflow_dispatch:
schedule:
- cron: "0 3 * * *"
jobs:
main:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout the repo
uses: actions/checkout@v4
with:
ref: ${{ github.head_ref }}
- name: Install Nix
uses: cachix/install-nix-action@v25
with:
extra_nix_config: |
substituters = https://cache.nixos.org https://42loco42.cachix.org https://attic.eleonora.gay/default
trusted-public-keys = cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY= 42loco42.cachix.org-1:6HvWFER3RdTSqEZDznqahkqaoI6QCOiX2gRpMMsThiQ= default:3FYh8sZV8gWa7Jc5jlP7gZFK7pt3kaHRiV70ySaQ42g=
- name: Update, build, push
run: |
old="$(sha256sum flake.lock)"
nix flake update nixpkgs-new
new="$(sha256sum flake.lock)"
if [ "$old" != "$new" ]; then
nix run -L .#nvidia
fi
env:
ATTIC_TOKEN: ${{ secrets.ATTIC_TOKEN }}
- name: Commit flake updates
uses: planetscale/[email protected]
with:
commit_message: "🤖 Update nixpkgs-new"
repo: ${{ github.repository }}
branch: ${{ github.head_ref || github.ref_name }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}