diff options
author | Linnnus <[email protected]> | 2023-09-05 09:48:04 +0200 |
---|---|---|
committer | Linnnus <[email protected]> | 2023-09-05 09:48:04 +0200 |
commit | 7d4ab89f1e6264e124109bf25eafaafdf1aec02a (patch) | |
tree | b6af29bfe66c231b1a71bb05c9df211afe4cf341 /hosts/muhammed |
Initial commit
Diffstat (limited to 'hosts/muhammed')
-rw-r--r-- | hosts/muhammed/configuration.nix | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/hosts/muhammed/configuration.nix b/hosts/muhammed/configuration.nix new file mode 100644 index 0000000..2645b80 --- /dev/null +++ b/hosts/muhammed/configuration.nix @@ -0,0 +1,31 @@ +# This file contains the configuration for my Macbook Pro. + +{ pkgs, inputs, lib, ... }: + +{ + # Specify the location of this configuration file. Very meta. + # environment.darwinConfig = inputs.self + "/hosts/muhammed/configuration.nix"; + + # Use the Nix daemon. + services.nix-daemon.enable = true; + + # Set up main account. + users.users.linus = { + description = "Personal user account"; + home = "/Users/linus"; + }; + + # Don't request password for running pmset. + environment.etc."sudoers.d/10-unauthenticated-commands".text = + let + commands = [ + "/usr/bin/pmset" + ]; + in + '' + %admin ALL=(ALL:ALL) NOPASSWD: ${builtins.concatStringsSep ", " commands} + ''; + + # Backwards compatability. Check `darwin-rebuild changelog` before bumping. + system.stateVersion = 4; +} |