diff --git a/share/config.fish b/share/config.fish
index b246916a5..05252c35f 100644
--- a/share/config.fish
+++ b/share/config.fish
@@ -132,6 +132,7 @@ and __fish_set_locale
 # This used to be in etc/config.fish - keep it here to keep the semantics
 #
 if status is-login && command -sq /usr/libexec/path_helper
+    and not set -q __NIX_DARWIN_SET_ENVIRONMENT_DONE
     __fish_macos_set_env PATH /etc/paths '/etc/paths.d'
     if test -n "$MANPATH"
         __fish_macos_set_env MANPATH /etc/manpaths '/etc/manpaths.d'
