about summary refs log tree commit diff
path: root/users/tazjin/nixos/modules/physical.nix
diff options
context:
space:
mode:
Diffstat (limited to 'users/tazjin/nixos/modules/physical.nix')
-rw-r--r--users/tazjin/nixos/modules/physical.nix176
1 files changed, 93 insertions, 83 deletions
diff --git a/users/tazjin/nixos/modules/physical.nix b/users/tazjin/nixos/modules/physical.nix
index 1f8b694381..bb85c6fb98 100644
--- a/users/tazjin/nixos/modules/physical.nix
+++ b/users/tazjin/nixos/modules/physical.nix
@@ -1,95 +1,105 @@
 # Default configuration settings for physical machines that I use.
-{ lib, pkgs, depot, ... }:
+{ lib, pkgs, config, depot, ... }:
 
 let
   pass-otp = pkgs.pass.withExtensions (e: [ e.pass-otp ]);
 in
 {
-  # Install all the default software.
-  environment.systemPackages =
-    # programs from the depot
-    (with depot; [
-      users.tazjin.screenLock
-      users.tazjin.emacs
-      third_party.agenix.cli
-      third_party.josh
-    ]) ++
+  options = with lib; {
+    tazjin.emacs = mkOption {
+      type = types.package;
+      default = depot.users.tazjin.emacs;
+      description = ''
+        Derivation with my Emacs package, with configuration included.
+      '';
+    };
+  };
 
-    # programs from nixpkgs
-    (with pkgs; [
-      amber
-      bat
-      curl
-      ddcutil
-      direnv
-      dnsutils
-      electrum
-      emacsNativeComp # emacsclient
-      exa
-      fd
-      file
-      firefox
-      gdb
-      gh
-      git
-      gnupg
-      google-chrome
-      gtk3 # for gtk-launch
-      htop
-      hyperfine
-      iftop
-      imagemagick
-      jq
-      lieer
-      man-pages
-      moreutils
-      mosh
-      msmtp
-      mullvad-vpn
-      networkmanagerapplet
-      nix-prefetch-github
-      nmap
-      notmuch
-      openssh
-      openssl
-      pass-otp
-      pavucontrol
-      pinentry
-      pinentry-emacs
-      pulseaudio # for pactl
-      pwgen
-      quasselClient
-      rink
-      ripgrep
-      rust-analyzer
-      rustup
-      screen
-      scrot
-      thunderbird
-      tig
-      tokei
-      tree
-      unzip
-      vlc
-      volumeicon
-      whois
-      xclip
-      xsecurelock
-      zoxide
-    ]);
+  config = {
+    # Install all the default software.
+    environment.systemPackages =
+      # programs from the depot
+      (with depot; [
+        users.tazjin.screenLock
+        users.tazjin.chase-geese
+        config.tazjin.emacs
+        third_party.agenix.cli
+      ]) ++
 
-  # Run services & configure programs for all machines.
-  services = {
-    mullvad-vpn.enable = true;
-    fwupd.enable = true;
-  };
+      # programs from nixpkgs
+      (with pkgs; [
+        (aspellWithDicts (d: [ d.ru ]))
+        amber
+        bat
+        curl
+        ddcutil
+        direnv
+        dnsutils
+        electrum
+        firefox
+        config.tazjin.emacs.emacs # emacsclient
+        expect
+        fd
+        file
+        gdb
+        git
+        gnupg
+        gtk3 # for gtk-launch
+        htop
+        hyperfine
+        iftop
+        imagemagick
+        josh
+        jq
+        lieer
+        maim
+        man-pages
+        moreutils
+        mosh
+        msmtp
+        networkmanagerapplet
+        nix-prefetch-github
+        nmap
+        notmuch
+        openssh
+        openssl
+        pass-otp
+        pavucontrol
+        pinentry
+        pinentry-emacs
+        pulseaudio # for pactl
+        pwgen
+        quasselClient
+        rink
+        ripgrep
+        rustup
+        screen
+        tig
+        tokei
+        tree
+        unzip
+        vlc
+        volumeicon
+        whois
+        xclip
+        xsecurelock
+        zoxide
+      ]);
+
+    # Run services & configure programs for all machines.
+    services.fwupd.enable = true;
+
+    # Disable the broken NetworkManager-wait-online.service
+    systemd.services.NetworkManager-wait-online.enable = lib.mkForce false;
 
-  # Disable the broken NetworkManager-wait-online.service
-  systemd.services.NetworkManager-wait-online.enable = lib.mkForce false;
+    # Disable the thing that prints annoying warnings when trying to
+    # run manually patchelfed binaries
+    environment.stub-ld.enable = false;
 
-  programs = {
-    fish.enable = true;
-    mosh.enable = true;
-    ssh.startAgent = true;
+    programs = {
+      fish.enable = true;
+      mosh.enable = true;
+      ssh.startAgent = true;
+    };
   };
 }