diff options
| author | Fuwn <[email protected]> | 2025-01-04 21:31:17 -0800 |
|---|---|---|
| committer | Fuwn <[email protected]> | 2025-01-04 21:31:17 -0800 |
| commit | d4c69a95f8f9e923081735b33cccc79311f93bb2 (patch) | |
| tree | 4621f50878fd9deaff3bf0de484199d4adfed40f /justfile | |
| parent | nara: pearcleaner (diff) | |
| download | nixos-config-d4c69a95f8f9e923081735b33cccc79311f93bb2.tar.xz nixos-config-d4c69a95f8f9e923081735b33cccc79311f93bb2.zip | |
just: default target to hostname
Diffstat (limited to 'justfile')
| -rw-r--r-- | justfile | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -1,10 +1,12 @@ +hostname := shell("hostname | sed 's/\\..*//' | tr '[:upper:]' '[:lower:]'") + default: @just --list action target action: git add . && rui --allow-unfree --allow-insecure {{target}} {{action}} -- --impure -build target: +build target=hostname: @uname | \ grep -q Darwin \ && just darwin_action {{target}} build \ @@ -13,7 +15,7 @@ build target: darwin_action target action: nix run nix-darwin -- {{action}} --flake .#{{target}} -switch target: +switch target=hostname: @uname | \ grep -q Darwin \ && just darwin_action {{target}} switch \ |