From 1f46f47a5762def867dc6188cba1fbca1d56e55f Mon Sep 17 00:00:00 2001 From: Takahito Nakano Date: Sat, 17 Oct 2026 17:58:14 +0900 Subject: [PATCH] chore(zsh): simplify environment setup --- home/.zshenv | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/home/.zshenv b/home/.zshenv index 976d654d..001b99e6 100644 --- a/home/.zshenv +++ b/home/.zshenv @@ -26,9 +26,7 @@ export __HOME_ZSHENV_SOURCED=1 # copied from /etc/zprofile # system-wide environment settings for zsh(1) -if [[ -x /usr/libexec/path_helper ]]; then - eval "$(/usr/libexec/path_helper -s)" -fi +test -x /usr/libexec/path_helper && eval "$($_ -s)" # mise # ref. https://mise.jdx.dev/bootstrap/packages/brew.html#the-prefix @@ -41,9 +39,7 @@ if command -v brew >/dev/null; then fi # Nix -if [[ -e /nix/var/nix/profiles/default/etc/profile.d/nix-daemon.sh ]]; then - source /nix/var/nix/profiles/default/etc/profile.d/nix-daemon.sh -fi +test -e /nix/var/nix/profiles/default/etc/profile.d/nix-daemon.sh && source "$_" # Prefer user-local binaries over other globally installed tools. path=("$XDG_BIN_HOME"(N-/) $path)