Nix system configuration for MacOS and NixOS

Prerequisites

Install

  • Clone this repository to ~/.dotfiles
git clone git@github.com:mackermans/dotfiles.git ~/.dotfiles

MacOS

nix run nix-darwin --extra-experimental-features "nix-command flakes" -- switch --flake ~/.dotfiles#nix-darwin
chsh -s /run/current-system/sw/bin/fish

NixOS

nix run nixos-rebuild --extra-experimental-features "nix-command flakes" -- switch --flake ~/.dotfiles#nixos

Usage

Update your system configuration to the latest version:

nix-rebuild
nix-rollback