nix-configs/justfile
Schrottkatze c42079235f
mreow
2025-01-03 19:04:46 +01:00

27 lines
1.1 KiB
Makefile

upgrade: update build
test:
sudo nixos-rebuild test --flake . --impure --log-format multiline
build:
sudo nixos-rebuild switch --flake . --impure --fast --log-format multiline
tbuild:
sudo nixos-rebuild switch --flake . --impure --fast --log-format multiline-with-logs --show-trace
update: update-typst-configs
nix flake update --commit-lock-file --log-format multiline
build-mac:
sudo nixos-rebuild switch --flake . --impure --override-input mac-brcm-fw path:/home/jade/mac-brcm-fw --fast --log-format multiline
update-typst-configs:
#!/usr/bin/env nu
let file = './modules/desktop-environment/home/typst.nix';
let $rev = http get https://forge.katzen.cafe/schrottkatze/typst-configs/commits/branch/main | query web -mq '.commit-list tr:first-of-type a.ui.sha.label' -a href | path basename | first;
./build-utils/templ-edit.nu edit $file REV $rev;
let $hash = nix-prefetch-url https://forge.katzen.cafe/schrottkatze/typst-configs/archive/main.tar.gz --unpack;
let $sri = nix hash to-sri --type sha256 $hash;
./build-utils/templ-edit.nu edit $file SHA $sri;
git add $file
git commit -m "typst-configs: Update"