From ac9a366aed7e0d4cbad304aa97d1a3da70f27fa5 Mon Sep 17 00:00:00 2001 From: Michael Hoang Date: Tue, 11 Jul 2023 18:52:49 +1000 Subject: [PATCH] uninstaller: remove `/Applications/Nix Apps` --- pkgs/darwin-uninstaller/configuration.nix | 6 ++---- pkgs/darwin-uninstaller/default.nix | 8 ++++---- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/pkgs/darwin-uninstaller/configuration.nix b/pkgs/darwin-uninstaller/configuration.nix index ca4ba1bf..d46d2436 100644 --- a/pkgs/darwin-uninstaller/configuration.nix +++ b/pkgs/darwin-uninstaller/configuration.nix @@ -14,10 +14,8 @@ with lib; launchd.user.agents = mkForce {}; system.activationScripts.postUserActivation.text = mkAfter '' - if test -L ~/Applications; then - rm ~/Applications - elif test -L ~/Applications/Nix\ Apps; then - rm ~/Applications/Nix\ Apps + if test -L /Applications/Nix\ Apps; then + rm /Applications/Nix\ Apps fi if test -L ~/.nix-defexpr/channels/darwin; then diff --git a/pkgs/darwin-uninstaller/default.nix b/pkgs/darwin-uninstaller/default.nix index 6df38790..ca7be489 100644 --- a/pkgs/darwin-uninstaller/default.nix +++ b/pkgs/darwin-uninstaller/default.nix @@ -45,10 +45,10 @@ stdenv.mkDerivation { echo >&2 echo >&2 "Uninstalling nix-darwin, this will:" echo >&2 - echo >&2 " - remove ~/Applications link." - echo >&2 " - cleanup static /etc files." - echo >&2 " - disable and remove all launchd services managed by nix-darwin." - echo >&2 " - restore daemon service from nix installer (only when this is a multi-user install)." + echo >&2 " - remove /Applications/Nix Apps symlink" + echo >&2 " - cleanup static /etc files" + echo >&2 " - disable and remove all launchd services managed by nix-darwin" + echo >&2 " - restore daemon service from nix installer (only when this is a multi-user install)" echo >&2 if test -t 0; then