-
-
Notifications
You must be signed in to change notification settings - Fork 442
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Programs installed via Nix are shadowed by preinstalled MacOS programs #337
Comments
It also happen when I install coreutils via Nix, which is quite irritating that in some shells I have access to Nix installed coreutils (when using Direnv) and sometimes I do not (when in "top-level" shell). |
Well, I'm not sure what I did wrong initially but I ended up just reinstalling macOS + Nix + Nix-Darwin and the proper paths are at the start now. Maybe there was some issue in Nix-Darwins ability to edit the /etc/zshrc or other related files, I'm not sure. But I don't have the issue anymore, although it seems like there might be others with the problem? (I didn't use direnv, though, so maybe it's a different issue). Should I leave this open or close it? |
Should be fixed by NixOS/nix#5179 |
I've just encountered this issue - is there any suggestions on how to fix it? It looks like nixpkgs source code hasn't regressed...
|
MacOS preinstalls Git in /usr/bin/git (which is really just a command to install Xcode dev tools). Anyways, when I install Git via Nix-Darwin, I'm unable to run it as it always defaults to the preinstalled one.
Checking out $PATH: /usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/zfs/bin:/Users/nate/.nix-profile/bin:/run/current-system/sw/bin:/nix/var/nix/profiles/default/bin I see that /usr/bin has precedence over my nix profile.
What's the "Nix way" to move that to the front of $PATH? I guess I could add it to zshrc but I'm not sure if that's the proper solution.
This doesn't happen with programs installed via nix-env, not sure why.
The text was updated successfully, but these errors were encountered: