diff --git a/setup.sh b/setup.sh index 21f2a3a..90cbaab 100755 --- a/setup.sh +++ b/setup.sh @@ -174,23 +174,8 @@ install_home_manager() { fi log_info "Installing Home Manager..." - if ! command -v nix-channel >/dev/null 2>&1; then - nix-channel --add "https://github.com/nix-community/home-manager/archive/release-$NIXOS_RELEASE.tar.gz" home-manager || \ - die "Failed to add home-manager channel" - else - sudo nix-channel --add "https://github.com/nix-community/home-manager/archive/release-$NIXOS_RELEASE.tar.gz" home-manager || \ - die "Failed to add home-manager channel" - fi - - if ! command -v nix-channel >/dev/null 2>&1; then - nix-channel --update || die "Failed to update channels" - else - sudo nix-channel --update || die "Failed to update channels" - fi - - if command -v nix-shell >/dev/null 2>&1; then - sudo nix-shell '' -A install || die "Failed to install home-manager (sudo)" - fi + nix-channel --add "https://github.com/nix-community/home-manager/archive/release-$NIXOS_RELEASE.tar.gz" home-manager || die "Failed to add home-manager channel" + nix-channel --update || die "Failed to update channels" nix-shell '' -A install || die "Failed to install home-manager" }