-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
How to completely remove Nix from OS X #458
Comments
Rm -rf /nix On Sat, Jan 24, 2015, 5:07 PM Matteo Ferrando notifications@github.com
|
Just an extra note for anyone finding this issue via google in future, to completely remove nix on OS X, I found I had to tidy up a couple of (now broken) symlinks in my home folder with |
Also don't forget to remove that |
You may also have persistent information in |
These tidbits should be added to the manual. Anyone want to submit a PR? |
On multi user systems you may want to check out the additional instructions at #1402. Instead of the manual it would be great to have an uninstall script that took care of everything. |
A probably naïve idea: what if the install script would generate an uninstall script and (try to) restore all that has been touched? As far as I can tell, https://nixos.org/nix/install is generated from the https://github.com/NixOS/nix/blob/master/scripts/install.in template (populated via https://github.com/NixOS/nix/blob/master/release.nix#L285). EDIT (2018/05/30 1457) |
From the multiuser installation script:
there may also be references to nix in |
I had a crack at writing an uninstall script for OSx. Hope someone finds this helpful! |
Hey @expelledboy, your script contains the following code: if [ -L $HOME/Applications ]; then
rm $HOME/Applications
fi I might be wrong, but that doesn't look safe to me. |
I am simply removing the link. Perhaps I could change it to use something like |
It just looks scary to run a script written by someone on the Internet that has a line that contains both "rm" and "$HOME/Applications". I'm sure that a seasoned programmer would immediately figure out if that's a malicious line or not, but noobs like me can't do it. Maybe worth it to add an explanatory comment above that code block. |
Also don't forget to delete relevant files in |
Also don't forget to delete a |
I did this and I ended up with an empty /nix folder, which caused the Nix installer to think I already have Nix installed and therefore it refused to reinstall Nix. Running
I tried disabling System Integrity Protection (SIP) and the above error remained. It took me a bit of research, but the solution is to edit the file EDIT: During reinstallation I noticed the below steps are printed, which is exactly what is required (some of which I forgot to mention):
|
Found a few more places where traces are left behind (docs helped here). I've rolled in bits and pieces from earlier comments as well.
This can probably be streamlined and (to a large extent) automated. There are probably still bits of Nix hiding away but this is the cleanest I've managed to get the system prior to reinstall so far. Side note for Nix maintainers, this removal has been performed in an attempt to fix |
To remove the "Nix Store" volume on Mac, you need to use the Disk Utility. I can't point out, how disappointed I am with nix... |
In addition to @Silic0nS0ldier's notes, there's also config at |
I used this guide: https://iohk.zendesk.com/hc/en-us/articles/4415830650265-Uninstall-nix-on-MacOS It's almost unbelievable that there is no provided uninstaller. |
This worked except for the last step, deleting the
I had to reboot the machine, after which it was mounted as
(intel mac running Monterey.) |
This is. the best example of why I (and other people) hate such programs that provide only installation scripts, and no uninstallation ones. Primitive? Yes. Intentional? Maybe. Irritating? Definitely. |
I already posted this on my gist. Anyone that comes here, just a heads up there are now official docs for uninstalling nix |
Everyone knows this. It's a matter of priorities, not lack of awareness. Comments like this are understandable, but ultimately without much value beyond catharsis for the author. Ironically this comment applies to itself: "Primitive? Yes. Intentional? Maybe. Irritating? Definitely." |
Sure, but I mean the whole point of Nix is to make it easy to replicate environments -- actually, that's not the point at all. The reason to spend front-loaded time to make it easy to replicate environments is precisely so that I don't spend a full weekend reading forums, copypasta from Stack Overflow, praying and leaving my wife feeling neglected. So, these comments are only "not helpful" if the many people behind Nix just naively feels like adding steroids to what is clearly the most useful offering on the market... |
Speaking of which, maybe something to that end can be arranged with "https://opencollective.com/nix-macos". If anyone wants to reach out to the necessary people and get |
Hi, I want to do a clean install of Nix on my computer, but I can't find how to uninstall it. In the manual, in chapter 4, it states the following:
But I'm on OS X. What steps should I follow?
The text was updated successfully, but these errors were encountered: