From 4717886bcc44762b04c640f14439461db8e0282f Mon Sep 17 00:00:00 2001 From: Evan Reichard Date: Sun, 6 Apr 2025 20:04:13 -0400 Subject: [PATCH] pointers & 3 drag --- .../evanreichard@mbp-nixos/default.nix | 19 +++++++++- .../wms/hyprland/config/hyprland.conf | 5 +-- modules/home/services/fusuma/default.nix | 35 +++++++++++++++++++ .../nixos/display-managers/sddm/default.nix | 10 +++--- modules/nixos/services/ydotool/default.nix | 19 ++++++++++ modules/nixos/user/default.nix | 5 +-- systems/aarch64-linux/mbp-nixos/default.nix | 14 +++----- 7 files changed, 86 insertions(+), 21 deletions(-) create mode 100644 modules/home/services/fusuma/default.nix create mode 100644 modules/nixos/services/ydotool/default.nix diff --git a/homes/aarch64-linux/evanreichard@mbp-nixos/default.nix b/homes/aarch64-linux/evanreichard@mbp-nixos/default.nix index 243f1ed..858eb0d 100755 --- a/homes/aarch64-linux/evanreichard@mbp-nixos/default.nix +++ b/homes/aarch64-linux/evanreichard@mbp-nixos/default.nix @@ -1,4 +1,4 @@ -{ lib, config, namespace, osConfig, ... }: +{ pkgs, lib, config, namespace, osConfig, ... }: let inherit (lib.${namespace}) enabled; in @@ -11,6 +11,7 @@ in services = { ssh-agent = enabled; + fusuma = enabled; sops = { enable = true; defaultSopsFile = lib.snowfall.fs.get-file "secrets/default.yaml"; @@ -40,6 +41,22 @@ in }; }; + dconf = { + settings = { + "org/gnome/desktop/interface" = { + cursor-theme = "catppuccin-macchiato-mauve-cursors"; + }; + }; + }; + + home.pointerCursor = { + x11.enable = true; + gtk.enable = true; + package = pkgs.catppuccin-cursors.macchiatoMauve; + name = "catppuccin-macchiato-mauve-cursors"; + size = 64; + }; + # Kubernetes Secrets sops.secrets = lib.mkIf osConfig.${namespace}.security.sops.enable { rke2_kubeconfig = { diff --git a/modules/home/programs/graphical/wms/hyprland/config/hyprland.conf b/modules/home/programs/graphical/wms/hyprland/config/hyprland.conf index 99b73f5..98dd3e2 100755 --- a/modules/home/programs/graphical/wms/hyprland/config/hyprland.conf +++ b/modules/home/programs/graphical/wms/hyprland/config/hyprland.conf @@ -163,10 +163,11 @@ input { sensitivity = 0 # -1.0 - 1.0, 0 means no modification. touchpad { - scroll_factor = 0.2 - disable_while_typing = true + scroll_factor = 0.2 + disable_while_typing = true natural_scroll = true clickfinger_behavior = true + tap-to-click = false } } diff --git a/modules/home/services/fusuma/default.nix b/modules/home/services/fusuma/default.nix new file mode 100644 index 0000000..51ef931 --- /dev/null +++ b/modules/home/services/fusuma/default.nix @@ -0,0 +1,35 @@ +{ config, pkgs, lib, namespace, ... }: +let + cfg = config.${namespace}.services.fusuma; +in +{ + options.${namespace}.services.fusuma = { + enable = lib.mkEnableOption "Fusuma"; + }; + + config = lib.mkIf cfg.enable { + services.fusuma = { + enable = true; + extraPackages = with pkgs; [ ydotool deterministic-uname uutils-coreutils-noprefix ]; + settings = { + swipe = { + "3" = { + begin = { + command = "ydotool click 40"; + interval = 0.00; + }; + update = { + command = "ydotool mousemove -- $move_x, $move_y"; + interval = 0.01; + accel = 1.00; + # accel = 1.70; + }; + end = { + command = "ydotool click 80"; + }; + }; + }; + }; + }; + }; +} diff --git a/modules/nixos/display-managers/sddm/default.nix b/modules/nixos/display-managers/sddm/default.nix index 6f1725b..6ad3d9f 100644 --- a/modules/nixos/display-managers/sddm/default.nix +++ b/modules/nixos/display-managers/sddm/default.nix @@ -14,11 +14,6 @@ in catppuccin-sddm ]; - environment.sessionVariables = { - QT_SCREEN_SCALE_FACTORS = "2"; - QT_FONT_DPI = "192"; - }; - services = { displayManager = { sddm = { @@ -29,5 +24,10 @@ in }; }; }; + + environment.sessionVariables = { + QT_SCREEN_SCALE_FACTORS = "2"; + QT_FONT_DPI = "192"; + }; }; } diff --git a/modules/nixos/services/ydotool/default.nix b/modules/nixos/services/ydotool/default.nix new file mode 100644 index 0000000..eebd2c0 --- /dev/null +++ b/modules/nixos/services/ydotool/default.nix @@ -0,0 +1,19 @@ +{ config, lib, namespace, ... }: +let + inherit (lib) mkIf; + + cfg = config.${namespace}.services.ydotool; +in +{ + options.${namespace}.services.ydotool = { + enable = lib.mkEnableOption "ydotool"; + }; + + config = mkIf cfg.enable { + reichard.user.extraGroups = [ "input" ]; + programs.ydotool = { + enable = true; + group = "input"; + }; + }; +} diff --git a/modules/nixos/user/default.nix b/modules/nixos/user/default.nix index 88f0d19..76f52b2 100644 --- a/modules/nixos/user/default.nix +++ b/modules/nixos/user/default.nix @@ -21,12 +21,9 @@ in users.users.${cfg.name} = { inherit (cfg) name initialPassword; - extraGroups = [ - "wheel" - ] ++ cfg.extraGroups; - group = "users"; home = "/home/${cfg.name}"; + extraGroups = [ "wheel" ] ++ cfg.extraGroups; isNormalUser = true; shell = pkgs.bashInteractive; uid = 1000; diff --git a/systems/aarch64-linux/mbp-nixos/default.nix b/systems/aarch64-linux/mbp-nixos/default.nix index e45c4df..1a93e0a 100755 --- a/systems/aarch64-linux/mbp-nixos/default.nix +++ b/systems/aarch64-linux/mbp-nixos/default.nix @@ -7,6 +7,9 @@ in ./hardware-configuration.nix ]; + system.stateVersion = "24.11"; + time.timeZone = "America/New_York"; + # System Config reichard = { nix = enabled; @@ -15,6 +18,7 @@ in boot = { enable = true; showNotch = true; + silentBoot = true; }; networking = { enable = true; @@ -33,6 +37,7 @@ in services = { avahi = enabled; + ydotool = enabled; }; security = { @@ -49,13 +54,4 @@ in }; }; }; - - # Hardware Config - hardware = { - bluetooth.enable = true; - bluetooth.powerOnBoot = true; - }; - - time.timeZone = "America/New_York"; - system.stateVersion = "24.11"; }