home-manager: move anything not hyprland-specific into desktop.nix

This commit is contained in:
Evie Litherland-Smith 2024-04-11 22:47:28 +01:00 committed by Evie Litherland-Smith
parent 1a1d58a199
commit 97e8a62ece
3 changed files with 66 additions and 63 deletions

63
home/desktop.nix Normal file
View file

@ -0,0 +1,63 @@
{
lib,
config,
pkgs,
catppuccinVariant ? "Mocha",
...
}: {
imports = [
./default.nix
./email/default.nix
./password-store/default.nix
./waybar/default.nix
./rofi/default.nix
./swaylock/default.nix
./swaync/default.nix
./avizo/default.nix
./alacritty/default.nix
./emacs/default.nix
./obs/default.nix
./cava/default.nix
];
programs.rofi.terminal = "${config.programs.alacritty.package}/bin/alacritty";
services = {
gpg-agent.pinentryFlavor = "gtk2";
avizo.enable = true;
syncthing.enable = true;
udiskie = {
enable = true;
notify = true;
automount = true;
tray = "never";
};
};
gtk = with lib.strings; let
accent = "Lavender";
size = "Standard";
in {
enable = true;
iconTheme = {
package = pkgs.catppuccin-papirus-folders.override {
accent = toLower accent;
flavor = toLower catppuccinVariant;
};
name = "Papirus-Dark";
};
cursorTheme = let
variant = "${lib.strings.toLower catppuccinVariant}Dark";
in {
package = pkgs.catppuccin-cursors.${variant};
name = "Catppuccin-${catppuccinVariant}-Dark-Cursors";
size = 32;
};
theme = {
package = with lib.strings;
pkgs.catppuccin-gtk.override {
accents = [(toLower accent)];
size = toLower size;
variant = toLower catppuccinVariant;
};
name = "Catppuccin-${catppuccinVariant}-${size}-${accent}-Dark";
};
};
}

View file

@ -5,23 +5,9 @@
fonts, fonts,
scheme, scheme,
accentColour ? "base07", accentColour ? "base07",
catppuccinVariant ? "Mocha",
... ...
}: { }: {
imports = [ imports = [../desktop.nix];
../default.nix
../email/default.nix
../password-store/default.nix
../waybar/default.nix
../rofi/default.nix
../swaylock/default.nix
../swaync/default.nix
../avizo/default.nix
../alacritty/default.nix
../emacs/default.nix
../obs/default.nix
../cava/default.nix
];
home.packages = with pkgs; [ home.packages = with pkgs; [
(writeShellScriptBin "protonmail-setup-bridge" '' (writeShellScriptBin "protonmail-setup-bridge" ''
pkill -9 -f protonmail-bridge pkill -9 -f protonmail-bridge
@ -29,54 +15,6 @@
${config.wayland.windowManager.hyprland.finalPackage}/bin/hyprctl dispatch exec "${protonmail-bridge}/bin/protonmail-bridge -n" ${config.wayland.windowManager.hyprland.finalPackage}/bin/hyprctl dispatch exec "${protonmail-bridge}/bin/protonmail-bridge -n"
'') '')
]; ];
programs = {
rofi = with pkgs; {
package = rofi-wayland;
terminal = "${config.programs.alacritty.package}/bin/alacritty";
pass.package = rofi-pass-wayland;
};
zellij.settings.copy_command = "wl-copy";
};
services = {
gpg-agent.pinentryFlavor = "gtk2";
avizo.enable = true;
syncthing.enable = true;
udiskie = {
enable = true;
notify = true;
automount = true;
tray = "never";
};
};
gtk = with lib.strings; let
accent = "Lavender";
size = "Standard";
in {
enable = true;
iconTheme = {
package = pkgs.catppuccin-papirus-folders.override {
accent = toLower accent;
flavor = toLower catppuccinVariant;
};
name = "Papirus-Dark";
};
cursorTheme = let
variant = "${lib.strings.toLower catppuccinVariant}Dark";
in {
package = pkgs.catppuccin-cursors.${variant};
name = "Catppuccin-${catppuccinVariant}-Dark-Cursors";
size = 32;
};
theme = {
package = with lib.strings;
pkgs.catppuccin-gtk.override {
accents = [(toLower accent)];
size = toLower size;
variant = toLower catppuccinVariant;
};
name = "Catppuccin-${catppuccinVariant}-${size}-${accent}-Dark";
};
};
wayland.windowManager.hyprland = { wayland.windowManager.hyprland = {
enable = true; enable = true;
xwayland.enable = true; xwayland.enable = true;

View file

@ -8,11 +8,13 @@
}: { }: {
programs.rofi = { programs.rofi = {
enable = true; enable = true;
package = pkgs.rofi-wayland;
font = fonts.monospace.name; font = fonts.monospace.name;
location = "center"; location = "center";
plugins = with pkgs; [rofi-emoji]; plugins = with pkgs; [rofi-emoji];
pass = { pass = {
enable = true; enable = true;
package = pkgs.rofi-wayland;
extraConfig = '' extraConfig = ''
USERNAME_field='login' USERNAME_field='login'
''; '';