From fe69cf30474c3b0d4cba20399ce33b404817bd4f Mon Sep 17 00:00:00 2001 From: emily Date: Thu, 29 Feb 2024 21:24:55 +0100 Subject: [PATCH] fixes --- config/common/users/emily/default.nix | 2 +- config/profiles/graphical/default.nix | 80 +++++++++++++++++++-------- config/profiles/graphical/nixvim.nix | 6 +- 3 files changed, 64 insertions(+), 24 deletions(-) diff --git a/config/common/users/emily/default.nix b/config/common/users/emily/default.nix index 157f57a..1114729 100644 --- a/config/common/users/emily/default.nix +++ b/config/common/users/emily/default.nix @@ -33,7 +33,7 @@ cider pavucontrol signal-desktop - element-desktop-wayland + element-desktop image-roll wl-clipboard diff --git a/config/profiles/graphical/default.nix b/config/profiles/graphical/default.nix index 63d067d..6c8fe46 100644 --- a/config/profiles/graphical/default.nix +++ b/config/profiles/graphical/default.nix @@ -12,6 +12,8 @@ boot.plymouth.enable = true; + security.pam.services.swaylock = {}; + services.geoclue2.enable = true; services.pipewire = { @@ -19,6 +21,9 @@ alsa.enable = true; pulse.enable = true; }; + + services.udisks2.enable = true; + environment.variables = { SDL_VIDEODRIVER = "wayland"; QT_QPA_PLATFORM = "wayland"; @@ -107,22 +112,6 @@ enable = true; source = config.stylix.image; }; - home.file.".local/bin/hypr" = { - enable = true; - executable = true; - recursive = true; - source = ./files/scripts; - }; - home.file.".config/mako-icons/" = { - enable = true; - recursive = true; - source = ./files/icons; - }; - home.file.".config/rofi" = { - enable = true; - recursive = true; - source = ./files/rofi; - }; wayland.windowManager.hyprland = { enable = true; settings = let @@ -265,14 +254,14 @@ "$mod, F2, exec, ${firefox}" # Rofi - "$mod, D, exec, ${rofi} -show drun -theme ~/.config/rofi/launcher.rasi" - "$mod, R, exec, ${rofi} -show run -theme ~/.config/rofi/runner.rasi" + "$mod, D, exec, ${rofi} -show drun -theme $XDG_CONFIG_HONE/rofi/launcher.rasi" + "$mod, R, exec, ${rofi} -show run -theme $XDG_CONFIG_HOME/rofi/runner.rasi" "$mod, X, exec, ~/.local/bin/hypr/rofi_powermenu.sh" "$mod, A, exec, ~/.local/bin/hypr/rofi_screenshot.sh" # Misc "$mod, C, exec, ~/.local/bin/hypr/colorpicker.sh" - "CTRL_ALT, L, exec, ${swaylock} -f -i ~/Pictures/wallpapers/lockscreen.png" + "CTRL_ALT, L, exec, ${swaylock} -f -i $XDG_PICTURES_DIR/wallpapers/lockscreen.png" # Function keys ", XF86MonBrightnessUp, exec, ${brightnessctl} s +10%" @@ -566,6 +555,18 @@ enable = true; package = pkgs.rofi-wayland; }; + + qt = { + enable = true; + platformTheme = "qtct"; + style.name = "kvantum-dark"; + style.package = with pkgs; [ + libsForQt5.qtstyleplugin-kvantum + qt6Packagee.qtstyleplugin-kvantum + (catppuccin-kvantum.override { accent = "Mauve"; variant = "Macchiato"; }) + ]; + }; + services.gammastep = { enable = true; provider = "geoclue2"; @@ -624,23 +625,58 @@ enable = true; systemdTarget = "hyprland-session.target"; events = [ - { event = "before-sleep"; command = "${swaylock} -f -i ~/Pictures/wallpapers/lockscreen.png"; } - { event = "lock"; command = "${swaylock} -f -i ~/Pictures/wallpapers/lockscreen.png"; } + { event = "before-sleep"; command = "${swaylock} -f -i ${config.home-manager.users.emily.xdg.userDirs.pictures}/wallpapers/lockscreen.png"; } + { event = "lock"; command = "${swaylock} -f -i ${config.home-manager.users.emily.xdg.userDirs.pictures}/wallpapers/lockscreen.png"; } ]; }; services.syncthing = { enable = true; tray.enable = true; - tray.command = "syncthingtray --wait"; + tray.command = "syncthingtray --replace"; }; services.udiskie = { enable = true; automount = false; }; + systemd.user.services.syncthingtray.Service = { + ExecStartPre = "${pkgs.coreutils-full}/bin/sleep 2"; + Restart = "on-failure"; + RestartSec = "1s"; + }; systemd.user.targets.tray.Unit = { BindsTo = "waybar.service"; After = "waybar.service"; }; + home.file.".local/bin/hypr" = { + enable = true; + executable = true; + recursive = true; + source = ./files/scripts; + }; + xdg.configFile."mako-icons" = { + enable = true; + recursive = true; + source = ./files/icons; + }; + xdg.configFile."rofi" = { + enable = true; + recursive = true; + source = ./files/rofi; + }; + xdg.userDirs = + let + home = config.home-manager.users.emily.home.homeDirectory; + in { + enable = true; + desktop = null; + documents = "${home}/docs"; + downloads = "${home}/Downloads"; + music = "${home}/music"; + pictures = "${home}/Pictures"; + publicShare = null; + templates = null; + videos = "${home}/videos"; + }; }; } diff --git a/config/profiles/graphical/nixvim.nix b/config/profiles/graphical/nixvim.nix index 8c89ac1..82bcc53 100644 --- a/config/profiles/graphical/nixvim.nix +++ b/config/profiles/graphical/nixvim.nix @@ -4,7 +4,10 @@ ]; home-manager.users.emily.programs.nixvim = { enable = true; - extraPlugins = [ pkgs.vimPlugins.molokai vimPlugins.vim-airline-themes ]; + extraPlugins = with pkgs; [ + vimPlugins.molokai + vimPlugins.vim-airline-themes + ]; colorscheme = "molokai"; vimAlias = true; highlightOverride.Normal = { @@ -13,6 +16,7 @@ }; options = { number = true; + expandtab = true; autoindent = true; mouse = ""; encoding = "utf-8";