{ description = "Tynan's nix-darwin system flake"; inputs = { nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable"; nix-darwin.url = "github:nix-darwin/nix-darwin/master"; nix-darwin.inputs.nixpkgs.follows = "nixpkgs"; }; outputs = inputs@{ self, nix-darwin, nixpkgs, ... }: let configuration = { pkgs, ... }: { security.pam.services.sudo_local.touchIdAuth = true; # List packages installed in system profile. To search by name, run: # $ nix-env -qaP | grep wget environment.systemPackages = with pkgs; [ neovim slack notion-app iterm2 discord bitwarden-desktop raycast net-news-wire bitwarden-desktop zed-editor obsidian # nix tools nixfmt ]; environment.variables = { GIT_AUTHOR_NAME = "Tynan Purdy"; GIT_AUTHOR_EMAIL = "did:plc:6ayddqghxhciedbaofoxkcbs"; }; system = { defaults = { CustomUserPreferences = { "com.apple.symbolichotkeys" = { AppleSymbolicHotKeys = { "64" = { # Disable 'Cmd + Space' for Spotlight Search enabled = false; }; }; }; }; dock = { # Dock settings autohide = true; show-recents = false; showAppExposeGestureEnabled = true; persistent-apps = [ "Applications/Zen.app" "Applications/Beeper Desktop.app" "${pkgs.discord}/Applications/Discord.app" "Applications/Fantastical.app" ]; }; finder = { FXPreferredViewStyle = "clmv"; ShowPathbar = true; _FXSortFoldersFirst = true; }; trackpad = { TrackpadThreeFingerVertSwipeGesture = 2; }; }; keyboard = { enableKeyMapping = true; remapCapsLockToEscape = true; }; primaryUser = "tynanpurdy"; }; homebrew = { enable = true; onActivation.cleanup = "zap"; brews = [ ]; casks = [ "todoist-app" "markedit" "qobuz" "zen" "stats" "affinity" "linearmouse" "figma" "beeper" "proton-mail-bridge" "monitorcontrol" "helium-browser" "tailscale-app" "orcaslicer" "webviewscreensaver" ]; masApps = { "Fantastical" = 975937182; "Aeronaut" = 6670275450; "Crouton" = 1461650987; "Barbee" = 1548711022; "Copilot Money" = 1447330651; "Flighty" = 1358823008; "Tripsy" = 1429967544; "Parcel" = 375589283; }; }; environment.shellAliases = { drs = "sudo darwin-rebuild switch --flake /etc/nix-darwin"; }; # Necessary for using flakes on this system. nix.settings.experimental-features = "nix-command flakes"; # Enable alternative shell support in nix-darwin. programs.fish.enable = true; # Set Git commit hash for darwin-version. system.configurationRevision = self.rev or self.dirtyRev or null; # Used for backwards compatibility, please read the changelog before changing. # $ darwin-rebuild changelog system.stateVersion = 6; # The platform the configuration will be used on. nixpkgs.hostPlatform = "aarch64-darwin"; nixpkgs.config.allowUnfree = true; }; in { # Build darwin flake using: # $ darwin-rebuild build --flake .#MacBook-Air darwinConfigurations."Kare" = nix-darwin.lib.darwinSystem { modules = [ configuration ]; }; }; }