From 90d9263c25dfb348d52e32f3308d9d85421aab45 Mon Sep 17 00:00:00 2001 From: Tyler Starr Date: Wed, 12 Mar 2025 23:37:03 -0700 Subject: [PATCH] move nixos update to justfile --- home/dot_aliases | 8 -------- justfile | 4 ++++ provision/readme.md | 2 +- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/home/dot_aliases b/home/dot_aliases index 3589a02c..2ce2d268 100644 --- a/home/dot_aliases +++ b/home/dot_aliases @@ -1,14 +1,6 @@ #!/usr/bin/env bash # https://github.com/starr-dusT/dotfiles -# nixos -alias nu="cd ~/.local/share/chezmoi/provision && \ - sudo nixos-rebuild switch --impure --flake .#$(hostname) && \ - cd -" -alias nb="cd ~/.local/share/chezmoi/provision && \ - sudo nix run .#nixosConfigurations.wsl.config.system.build.tarballBuilder && \ - cd -" - # sesh function b() { { diff --git a/justfile b/justfile index 0bf6fad8..fb4f1880 100644 --- a/justfile +++ b/justfile @@ -1,4 +1,8 @@ [working-directory: 'provision'] +update: + cd ~/.local/share/chezmoi/provision + sudo nixos-rebuild switch --impure --flake .#$(hostname) + build-wsl: cd ~/.local/share/chezmoi/provision sudo nix run .#nixosConfigurations.wsl.config.system.build.tarballBuilder diff --git a/provision/readme.md b/provision/readme.md index 776cb771..485a80fe 100644 --- a/provision/readme.md +++ b/provision/readme.md @@ -32,4 +32,4 @@ Perform additional setup found in [additional-setup](additional-setup.md) ## Update -`nixos-rebuild` command is aliased to `nu` assuming the machine's flake output is named the same at the hostname of the machine. +`nixos-rebuild` command is built into the `justfile` with this folder, assuming the machine's flake output is named the same at the hostname of the machine.