improve comments and general tweaks

This commit is contained in:
Noah Masur
2022-05-29 13:44:45 -04:00
parent 3ea0e40121
commit 3ba26ccfd5
14 changed files with 76 additions and 34 deletions

View File

@ -32,8 +32,11 @@ in {
config = lib.mkIf config.gui.enable {
sound.enable = true;
# Enable PulseAudio
hardware.pulseaudio.enable = true;
# These aren't necessary, but helpful for the user
environment.systemPackages = with pkgs; [
pamixer # Audio control
volnoti # Volume notifications
@ -44,15 +47,28 @@ in {
# Graphical volume notifications
services.volnoti.enable = true;
# i3 keybinds for changing the volume
xsession.windowManager.i3.config.keybindings = {
"XF86AudioRaiseVolume" =
"exec --no-startup-id ${increaseVolume}/bin/increaseVolume";
"XF86AudioLowerVolume" =
"exec --no-startup-id ${decreaseVolume}/bin/decreaseVolume";
"XF86AudioMute" = "exec --no-startup-id ${toggleMute}/bin/toggleMute";
"XF86AudioMicMute" =
"exec --no-startup-id pamixer --default-source --toggle-mute";
xsession.windowManager.i3.config = {
# Make sure that Volnoti actually starts (home-manager doesn't start
# user daemon's automatically)
startup = [{
command = "systemctl --user restart volnoti";
always = true;
notification = false;
}];
# i3 keybinds for changing the volume
keybindings = {
"XF86AudioRaiseVolume" =
"exec --no-startup-id ${increaseVolume}/bin/increaseVolume";
"XF86AudioLowerVolume" =
"exec --no-startup-id ${decreaseVolume}/bin/decreaseVolume";
"XF86AudioMute" = "exec --no-startup-id ${toggleMute}/bin/toggleMute";
# We can mute the mic by adding "--default-source"
"XF86AudioMicMute" =
"exec --no-startup-id ${pkgs.pamixer}/bin/pamixer --default-source --toggle-mute";
};
};
};

View File

@ -1,6 +1,7 @@
{ ... }: {
# Use the systemd-boot EFI boot loader.
# These came with the system and I don't know if they're required.
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;

View File

@ -1,13 +1,16 @@
{ ... }: {
services.xserver = {
layout = "us";
# Keyboard responsiveness
autoRepeatDelay = 250;
autoRepeatInterval = 40;
# Configure keymap in X11
layout = "us";
# Swap escape key with caps lock key
xkbOptions = "eurosign:e,caps:swapescape";
};
}

View File

@ -19,10 +19,10 @@
};
};
# Detect monitors (brightness)
# Detect monitors (brightness) for ddcutil
hardware.i2c.enable = true;
# Grant user access to external monitors
# Grant main user access to external monitors
users.users.${config.user}.extraGroups = [ "i2c" ];
services.xserver.displayManager = {

View File

@ -2,7 +2,7 @@
config = lib.mkIf config.gui.enable {
# Mouse config
# Mouse customization
services.ratbagd.enable = true;
environment.systemPackages = with pkgs; [

View File

@ -2,8 +2,7 @@
# Prevent wake from keyboard
powerManagement.powerDownCommands = ''
echo disabled > /sys/bus/usb/devices/1-6/power/wakeup
echo disabled > /sys/bus/usb/devices/1-8/power/wakeup
for wakeup in /sys/bus/usb/devices/1-*/power/wakeup; do echo disabled > $wakeup; done
'';
}

View File

@ -1,7 +1,9 @@
{ ... }: {
networking.wireless.enable =
true; # Enables wireless support via wpa_supplicant.
# Enables wireless support via wpa_supplicant.
networking.wireless.enable = true;
# Allows the user to control the WiFi settings.
networking.wireless.userControlled.enable = true;
}