From c7d92b852e16570204b400b9be20187348b4d423 Mon Sep 17 00:00:00 2001 From: Daiderd Jordan Date: Thu, 11 May 2017 21:36:57 +0200 Subject: [PATCH] darwin-rebuild: run user activation first Some of the activation scripts use /run/current-system as a reference for things that should be removed. The symlink is updated by the system activation script thus it should run last. --- pkgs/nix-tools/darwin-rebuild.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/nix-tools/darwin-rebuild.sh b/pkgs/nix-tools/darwin-rebuild.sh index 18d7686..7dbe5d3 100644 --- a/pkgs/nix-tools/darwin-rebuild.sh +++ b/pkgs/nix-tools/darwin-rebuild.sh @@ -94,11 +94,11 @@ if [ "$action" = switch ]; then nix-env -p $profile --set $systemConfig fi + $systemConfig/activate-user + if [ "$USER" != root ]; then sudo $systemConfig/activate else $systemConfig/activate fi - - $systemConfig/activate-user fi