From 801b1caf2aee808aacb46b2fce8b8e62aac224d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20Av=C3=A9?= Date: Sat, 1 Feb 2025 13:43:19 +0100 Subject: [PATCH] Hyprlock --- home/Aloria.nix | 14 +++++++++----- home/Arendia.nix | 4 ---- home/hyprland/default.nix | 34 ++++++++++++++++++++++++++++++++-- 3 files changed, 41 insertions(+), 11 deletions(-) diff --git a/home/Aloria.nix b/home/Aloria.nix index 3307668..9c5d359 100644 --- a/home/Aloria.nix +++ b/home/Aloria.nix @@ -1,8 +1,16 @@ { inputs, config, pkgs, ... }: - +let + fzgo_paths = [ + "/home/user/.dotfiles" + "/home/server/.cache/fzgo/entries/d/|home|server|Workspace" + "/home/server/.cache/fzgo/entries/d/|home|server|Storage|Thomas" + "/home/server/.cache/fzgo/entries/d/|home|server|Storage|Shared" + ]; +in { imports = [ (import ./utils/desktop.nix { inherit inputs config pkgs; }) + (import ./utils/fzgo_links.nix { inherit config pkgs fzgo_paths; }) ]; programs.ssh.matchBlocks."*".identityFile = "/home/user/.secrets/SSH/Aloria/id_ed25519"; @@ -44,8 +52,4 @@ programs.alacritty.settings.font.size = 12; programs.kitty.font.size = 12; - programs.zsh.initExtra = pkgs.lib.mkForce '' - LOCAL_SEARCH_DIRS=(~/.dotfiles/) - REMOTE_SEARCH_DIRS=( ~/Workspace) - ''; } diff --git a/home/Arendia.nix b/home/Arendia.nix index 51ae02b..cd4b05b 100644 --- a/home/Arendia.nix +++ b/home/Arendia.nix @@ -50,8 +50,4 @@ in programs.alacritty.settings.font.size = 13; programs.kitty.font.size = 13; - programs.zsh.initExtra = pkgs.lib.mkForce '' - LOCAL_SEARCH_DIRS=(~/.dotfiles/) - REMOTE_SEARCH_DIRS=( ~/Workspace) - ''; } diff --git a/home/hyprland/default.nix b/home/hyprland/default.nix index ef62703..03a93dd 100644 --- a/home/hyprland/default.nix +++ b/home/hyprland/default.nix @@ -7,7 +7,6 @@ let wpctl = "${pkgs.wireplumber}/bin/wpctl"; terminal-name = ".kitty-wrapped"; terminal = "${pkgs.kitty}/bin/kitty"; - swaylock = "${pkgs.swaylock-fancy}/bin/swaylock-fancy"; rofi = "${pkgs.rofi}/bin/rofi"; jq = "${pkgs.jq}/bin/jq"; rofi-ykman = pkgs.writeShellScriptBin "rofi-ykman" '' @@ -90,6 +89,37 @@ in { }; }; + programs.hyprlock = { + enable = true; + settings = { + input-field = [ + { + size = "200, 50"; + position = "0, -80"; + monitor = ""; + dots_center = true; + fade_on_empty = true; + font_color = "rgb(202, 211, 245)"; + inner_color = "rgb(91, 96, 120)"; + outer_color = "rgb(24, 25, 38)"; + outline_thickness = 3; + placeholder_text = "Password..."; + shadow_passes = 2; + } + ]; + general = { + no_fade_in = false; + }; + background = [ + { + path = "screenshot"; + blur_passes = 3; + blur_size = 8; + } + ]; + }; + }; + wayland.windowManager.hyprland = { enable = true; systemd.variables = [ "--all" ]; @@ -196,7 +226,7 @@ in { "$mainMod, F11, fullscreen" "$mainMod, F, togglefloating," "$mainMod, SPACE, togglesplit, # dwindle" - "CONTROL_L ALT_L, L, exec, ${swaylock}" + "CONTROL_L ALT_L, L, exec, ${pkgs.hyprlock}/bin/hyprlock" ''$mainMod, C, exec, cliphist list | awk '{print $0, "\0icon\x1fcom.github.davidmhewitt.clipped"; }' | ${rofi} -dmenu -display-columns 2 | cliphist decode | wl-copy'' "$mainMod, Y, exec, ${rofi-ykman}/bin/rofi-ykman" "$mainMod, N, exec, ${./files/rofi-ssh.sh}"