Created
August 7, 2020 15:47
-
-
Save dmjio/2507643b4612872edade98dac5d6f58c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# run these two lines first | |
echo 'nix' | sudo tee -a /etc/synthetic.conf # or edit this file and just add nix | |
/System/Library/Filesystems/apfs.fs/Contents/Resources/apfs.util -B | |
[ 0 -ne "$?" ] && echo "Restarting APFS failed, please reboot your computer" | |
# reboot if it tells you to reboot | |
# then run this | |
sudo diskutil apfs addVolume disk1 APFSX Nix -mountpoint /nix # make sure disk1 is correct | |
sudo diskutil enableOwnership /nix | |
sudo chown -R $(whoami) /nix | |
sudo chflags hidden /nix # if you don't want to see Nix volume in finder | |
echo "LABEL=Nix /nix apfs rw" | sudo tee -a /etc/fstab | |
# now, install nix | |
curl https://nixos.org/nix/install | sh |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment