From 27bea676b1c4cc738e6506f6e897d1f5246d5377 Mon Sep 17 00:00:00 2001 From: seth Date: Fri, 8 Mar 2024 12:35:32 -0500 Subject: justfile: passthrough more flags --- justfile | 35 +++++++++++++++++++++++------------ 1 file changed, 23 insertions(+), 12 deletions(-) (limited to 'justfile') diff --git a/justfile b/justfile index 5d4d689..833e151 100644 --- a/justfile +++ b/justfile @@ -13,25 +13,34 @@ default: @just --choose [private] -rebuild subcmd: +rebuild subcmd *extraArgs="": {{ rebuild }} {{ subcmd }} {{ rebuildArgs }} --flake . -build: (rebuild "build") +build *extraArgs="": (rebuild "build" extraArgs) -dry-run: (rebuild "dry-run") +dry-run *extraArgs="": (rebuild "dry-run" extraArgs) -switch: (rebuild "switch") +switch *extraArgs="": (rebuild "switch" extraArgs) -test: (rebuild "test") +test *extraArgs="": (rebuild "test" extraArgs) -check: +check *args="": nix flake check \ --print-build-logs \ --show-trace \ - --accept-flake-config + --accept-flake-config \ + {{ args }} + +eval system *args="": + nix eval \ + --raw \ + '.#nixosConfigurations.{{ system }}.config.system.build.toplevel' \ + {{ args }} update: - nix flake update + nix flake update \ + --commit-lock-file \ + --commit-lockfile-summary "flake: update all inputs" update-input input: nix flake lock \ @@ -39,16 +48,18 @@ update-input input: --commit-lock-file \ --commit-lockfile-summary "flake: update {{ input }}" -deploy system: +deploy system *args="": nix run \ --inputs-from . \ 'nixpkgs#deploy-rs' -- \ - -s '.#{{ system }}' + '.#{{ system }}' \ + {{ args }} -deploy-all: +deploy-all *args="": nix run \ --inputs-from . \ - 'nixpkgs#deploy-rs' -- -s + 'nixpkgs#deploy-rs' -- \ + {{ args }} clean: rm -rf \ -- cgit v1.2.3