summary refs log tree commit diff stats
path: root/system/settings
diff options
context:
space:
mode:
Diffstat (limited to 'system/settings')
-rw-r--r--system/settings/configuration/networking.nix11
-rw-r--r--system/settings/hardware/intel-gpu.nix18
-rw-r--r--system/settings/hardware/laptop.nix79
-rw-r--r--system/settings/hardware/network-manager.nix16
-rw-r--r--system/settings/hardware/personal-computer.nix8
-rw-r--r--system/settings/hardware/thinkpad.nix23
-rw-r--r--system/settings/hardware/trackball.nix15
-rw-r--r--system/settings/machines/t470s.nix57
-rw-r--r--system/settings/programs/barrier.nix10
-rw-r--r--system/settings/programs/gnome.nix26
-rw-r--r--system/settings/programs/tor.nix27
-rw-r--r--system/settings/programs/window-manager.nix57
-rw-r--r--system/settings/programs/xfce.nix8
13 files changed, 0 insertions, 355 deletions
diff --git a/system/settings/configuration/networking.nix b/system/settings/configuration/networking.nix
deleted file mode 100644
index ad4200b1..00000000
--- a/system/settings/configuration/networking.nix
+++ /dev/null
@@ -1,11 +0,0 @@
-{ config
-, pkgs
-, ...
-}: {
-  environment.systemPackages = with pkgs; [ lxqt.lxqt-policykit ]; # provides a default authentification client for policykit
-  services.gvfs.enable = true; # enables gvfs
-
-  imports = [
-    ../services/zeroconf.nix
-  ];
-}
diff --git a/system/settings/hardware/intel-gpu.nix b/system/settings/hardware/intel-gpu.nix
deleted file mode 100644
index 494cb86e..00000000
--- a/system/settings/hardware/intel-gpu.nix
+++ /dev/null
@@ -1,18 +0,0 @@
-{ config
-, pkgs
-, ...
-}: {
-  # https://wiki.gentoo.org/wiki/Intel#Feature_support
-  services.xserver = {
-    useGlamor = true;
-    deviceSection = ''
-      Option      "DRI"            "3"
-    '';
-    videoDrivers = [ "intel" ];
-  };
-
-  boot.kernelParams = [
-    "i915.enable_guc=2"
-    "i915.fastboot=1"
-  ];
-}
diff --git a/system/settings/hardware/laptop.nix b/system/settings/hardware/laptop.nix
deleted file mode 100644
index bd66fb8f..00000000
--- a/system/settings/hardware/laptop.nix
+++ /dev/null
@@ -1,79 +0,0 @@
-{ config
-, pkgs
-, lib
-, ...
-}: {
-  imports = [
-    ./bluetooth.nix
-    ./bluetooth-audio.nix
-    ./connman.nix
-    ./iwd.nix
-    ./personal-computer.nix
-    ../user-interface.nix
-  ];
-
-  boot.kernelModules = [ "coretemp" ];
-
-  environment.systemPackages = with pkgs; [
-    powerstat
-    powertop
-
-    arandr
-    autorandr
-  ];
-
-  programs.light.enable = true;
-
-  services.autorandr = {
-    enable = true;
-    defaultTarget = "common";
-  };
-  systemd.services.autorandr.wantedBy = [ "graphical.target" ];
-
-  environment.etc.autorandr = {
-    enable = true;
-    source = ../../autorandr;
-    target = "xdg/autorandr";
-  };
-
-  services.logind = {
-    lidSwitch = "suspend";
-    lidSwitchExternalPower = "ignore";
-    extraConfig = ''
-      IdleAction=suspend
-      IdleActionSec=600
-    '';
-  };
-
-  services.acpid = {
-    enable = true;
-    lidEventCommands = ''
-      ${pkgs.autorandr}/bin/autorandr --batch --change
-    '';
-  };
-
-  services.tlp = {
-    extraConfig = ''
-      CPU_SCALING_GOVERNOR_ON_BAT=powersave
-      ENERGY_PERF_POLICY_ON_BAT="balance_power"
-
-      SOUND_POWER_SAVE_ON_AC=60
-      DEVICES_TO_DISABLE_ON_BAT_NOT_IN_USE="bluetooth wwan"
-    '';
-  };
-
-  services.xserver = {
-    libinput = {
-      enable = lib.mkDefault true;
-      naturalScrolling = true;
-      disableWhileTyping = true;
-    };
-    displayManager.sessionCommands = ''
-      ${pkgs.autorandr}/bin/autorandr --change --force
-    '';
-  };
-
-  systemd.services.nixos-upgrade.unitConfig.ConditionACPower = true;
-  systemd.services.nix-gc.unitConfig.ConditionACPower = true;
-  systemd.services.docker-prune.unitConfig.ConditionACPower = true;
-}
diff --git a/system/settings/hardware/network-manager.nix b/system/settings/hardware/network-manager.nix
deleted file mode 100644
index a27ca892..00000000
--- a/system/settings/hardware/network-manager.nix
+++ /dev/null
@@ -1,16 +0,0 @@
-{ config
-, lib
-, pkgs
-, ...
-}: {
-  networking = {
-    networkmanager = {
-      enable = true;
-    };
-  };
-
-  environment.systemPackages = with pkgs; [
-    networkmanagerapplet
-    networkmanager_dmenu
-  ];
-}
diff --git a/system/settings/hardware/personal-computer.nix b/system/settings/hardware/personal-computer.nix
deleted file mode 100644
index 35824136..00000000
--- a/system/settings/hardware/personal-computer.nix
+++ /dev/null
@@ -1,8 +0,0 @@
-{ config
-, pkgs
-, lib
-, ...
-}: {
-  boot.kernelPackages = lib.mkDefault pkgs.linuxPackages_zen;
-  powerManagement.cpuFreqGovernor = "schedutil";
-}
diff --git a/system/settings/hardware/thinkpad.nix b/system/settings/hardware/thinkpad.nix
deleted file mode 100644
index 649f626a..00000000
--- a/system/settings/hardware/thinkpad.nix
+++ /dev/null
@@ -1,23 +0,0 @@
-{ config
-, pkgs
-, ...
-}: {
-  boot.kernelModules = [ ];
-  boot.blacklistedKernelModules = [ "thinkpad_ec" ];
-  boot.extraModulePackages = with config.boot.kernelPackages; [
-    acpi_call
-  ];
-
-  services.fwupd = {
-    enable = true;
-  };
-
-  services.thinkfan = {
-    enable = true;
-  };
-
-  imports = [
-    ./bare-metal.nix
-    ./laptop.nix
-  ];
-}
diff --git a/system/settings/hardware/trackball.nix b/system/settings/hardware/trackball.nix
deleted file mode 100644
index c2f7e68c..00000000
--- a/system/settings/hardware/trackball.nix
+++ /dev/null
@@ -1,15 +0,0 @@
-{ config
-, pkgs
-, ...
-}: {
-  services.xserver.config = ''
-    Section "InputClass"
-        Identifier "Trackball (No Acceleration)"
-        MatchIsPointer "yes"
-        MatchIsTouchpad "no"
-        MatchProduct "Trackball"
-        Option "AccelerationProfile" "-1"
-        Option "AccelerationScheme" "none"
-    EndSection
-  '';
-}
diff --git a/system/settings/machines/t470s.nix b/system/settings/machines/t470s.nix
deleted file mode 100644
index 5f1f4a1c..00000000
--- a/system/settings/machines/t470s.nix
+++ /dev/null
@@ -1,57 +0,0 @@
-{ config
-, pkgs
-, ...
-}: {
-  hardware.usbWwan.enable = false; # unused
-  systemd.services.ModemManager.enable = false;
-
-  hardware.enableRedistributableFirmware = true;
-
-  boot.extraModprobeConfig = ''
-    options thinkpad_acpi fan_control=1
-  '';
-
-  services.thinkfan.sensors = ''
-    hwmon /sys/devices/platform/coretemp.0/hwmon/hwmon0/temp3_input
-    hwmon /sys/devices/platform/coretemp.0/hwmon/hwmon0/temp1_input
-    hwmon /sys/devices/platform/coretemp.0/hwmon/hwmon0/temp2_input
-  '';
-  services.thinkfan.levels = ''
-    (0,     0,      48)
-    (1,     45,     52)
-    (2,     50,     57)
-    (3,     55,     63)
-    (6,     60,     65)
-    (7,     60,     85)
-    (127,   80,     32767)
-  '';
-
-  boot.postBootCommands = ''
-    echo bfq > /sys/block/nvme0n1/queue/scheduler
-  '';
-
-  hardware.pulseaudio.extraConfig = ''
-    load-module module-alsa-sink device=hw:0,7
-  '';
-
-  services.tlp.extraConfig = ''
-    DISK_DEVICES="nvme0n1"
-    DISK_IOSCHED="keep"
-  '';
-
-  services.xserver = {
-    dpi = 109;
-    monitorSection = ''
-      DisplaySize 310 176
-    '';
-  };
-
-  environment.systemPackages = with pkgs; [
-    nvme-cli
-  ];
-
-  imports = [
-    ../hardware/intel-gpu.nix
-    ../hardware/thinkpad.nix
-  ];
-}
diff --git a/system/settings/programs/barrier.nix b/system/settings/programs/barrier.nix
deleted file mode 100644
index 76e1b06b..00000000
--- a/system/settings/programs/barrier.nix
+++ /dev/null
@@ -1,10 +0,0 @@
-{ config
-, pkgs
-, ...
-}: {
-  environment.systemPackages = with pkgs; [
-    barrier
-  ];
-
-  networking.firewall.allowedTCPPorts = [ 24800 ];
-}
diff --git a/system/settings/programs/gnome.nix b/system/settings/programs/gnome.nix
deleted file mode 100644
index f9618009..00000000
--- a/system/settings/programs/gnome.nix
+++ /dev/null
@@ -1,26 +0,0 @@
-{ config
-, lib
-, pkgs
-, ...
-}:
-with lib; {
-  services = {
-    gnome3 = {
-      gnome-documents.enable = false;
-      gnome-user-share.enable = false;
-      gnome-online-accounts.enable = false;
-      tracker.enable = false;
-    };
-    telepathy.enable = false;
-
-    xserver = {
-      desktopManager.gnome3 = {
-        enable = true;
-        extraGSettingsOverrides = ''
-          [org.gnome.desktop.input-sources]
-          sources=[('xkb','${config.services.xserver.layout + (optionalString (config.services.xserver.xkbVariant != "") ("+" + config.services.xserver.xkbVariant))}')]
-        '';
-      };
-    };
-  };
-}
diff --git a/system/settings/programs/tor.nix b/system/settings/programs/tor.nix
deleted file mode 100644
index 31521857..00000000
--- a/system/settings/programs/tor.nix
+++ /dev/null
@@ -1,27 +0,0 @@
-{ config
-, pkgs
-, lib
-, ...
-}: {
-  services.tor = {
-    enable = true;
-    client = {
-      enable = true;
-      socksListenAddress = {
-        IPv6Traffic = true;
-        port = 9050;
-      };
-    };
-    torsocks = {
-      enable = true;
-    };
-  };
-  systemd.services.tor.wantedBy = lib.mkForce [ ];
-  systemd.timers.tor = {
-    description = "Delayed startup of Tor";
-    wantedBy = [ "timers.target" ];
-    timerConfig = {
-      OnActiveSec = "1 min";
-    };
-  };
-}
diff --git a/system/settings/programs/window-manager.nix b/system/settings/programs/window-manager.nix
deleted file mode 100644
index bbe4c638..00000000
--- a/system/settings/programs/window-manager.nix
+++ /dev/null
@@ -1,57 +0,0 @@
-{ config
-, pkgs
-, lib
-, ...
-}: {
-  services.xserver = {
-    desktopManager.xterm.enable = false;
-
-    displayManager = {
-      autoLogin = {
-        user = "alan";
-        enable = false;
-      };
-      lightdm = {
-        enable = true;
-        greeter.enable = true;
-        greeters.mini = {
-          enable = false;
-          user = "alan";
-        };
-      };
-      sessionCommands = ''
-        ${pkgs.xorg.xrdb}/bin/xrdb -merge $HOME/.xresources/main
-        ${pkgs.xorg.xsetroot}/bin/xsetroot -cursor_name left_ptr -solid '#4d4d4c'
-      '' ++ (lib.optionalString config.networking.networkmanager.enable ''
-        ${pkgs.networkmanagerapplet}/bin/nm-applet &
-      '');
-    };
-    xautolock = {
-      enable = true;
-      locker = "${pkgs.i3lock}/bin/i3lock -n";
-      enableNotifier = true;
-      notifier = "${pkgs.libnotify}/bin/notify-send \"Locking in 10 seconds\"";
-      time = 5;
-    };
-  };
-
-  services.xserver.displayManager.setupCommands = ''
-    ${pkgs.redshift}/bin/redshift \
-    -l ${toString config.location.latitude}:${toString config.location.longitude} \
-    -t ${toString config.services.redshift.temperature.day}:${toString config.services.redshift.temperature.night} \
-    -b 1:1 \
-    -o \
-    -r
-  '';
-
-  environment.systemPackages = with pkgs; [
-    dmenu
-    libnotify # for notify-send
-    xterm
-    rofi
-    sxhkd
-    maim
-
-    perlPackages.FileMimeInfo # xdg-utils uses this when no DE
-  ];
-}
diff --git a/system/settings/programs/xfce.nix b/system/settings/programs/xfce.nix
deleted file mode 100644
index a896810a..00000000
--- a/system/settings/programs/xfce.nix
+++ /dev/null
@@ -1,8 +0,0 @@
-{ pkgs, ... }: {
-  services.xserver.desktopManager.xfce = {
-    enable = true;
-  };
-  environment.systemPackages = with pkgs; [
-    xfce.xfce4-panel-profiles
-  ];
-}