From 7500b12ed9e4c57223743048830abc232d46973d Mon Sep 17 00:00:00 2001 From: Sean Buckley Date: Tue, 21 Jun 2022 23:28:28 -0400 Subject: [PATCH] add sc-check script --- modules/sean.nix | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/modules/sean.nix b/modules/sean.nix index 1dda0f9..b2f5ac3 100644 --- a/modules/sean.nix +++ b/modules/sean.nix @@ -27,9 +27,16 @@ in systemd.tmpfiles.rules = [ "e /home/sean/Downloads - - - 9d" ]; - environment.systemPackages = map - (x: (pkgs.writeShellScriptBin "sc-${x}" "nixos-rebuild ${x} --refresh --flake bck")) - [ "boot" "build" "switch" "test" ]; + environment.systemPackages = + [ + (pkgs.writeShellScriptBin "sc-check" '' + readlink /run/current-system + nix eval --raw "bck#nixosConfigurations.$(hostname).config.system.build.toplevel" + '') + ] + ++ map + (x: (pkgs.writeShellScriptBin "sc-${x}" "nixos-rebuild ${x} --refresh --flake bck")) + [ "boot" "build" "switch" "test" ]; sconfig.user-settings = '' git config --global user.email "sean.bck@gmail.com"