This repository has been archived on 2024-07-03. You can view files and clone it, but cannot push or open issues or pull requests.
home-manager/programs/desktop/default.nix
Evie Litherland-Smith 22dbc09500 Move some config from home/default.nix and nixos system config
Add options to desktop.nix from home/default.nix that are
desktop-relevant.

Add mimeapp config back from nixos system config

Move fd, ripgrep to enabled programs, remmina to enable service

Emacs config now imports shell config to ensure requirements are met
instead of duplicating some

Move Zsh config into it's own file zsh.nix
2024-06-07 10:51:35 +01:00

139 lines
3.4 KiB
Nix

{
config,
lib,
pkgs,
catppuccinVariant ? "Mocha",
...
}: {
imports = [
./sway/default.nix
./niri/default.nix
./foot/default.nix
./alacritty/default.nix
./avizo/default.nix
./fuzzel/default.nix
./swaylock/default.nix
./swayidle/default.nix
./mako/default.nix
./waybar/default.nix
./wlogout/default.nix
];
home.packages = with pkgs; [
pinentry
ffmpeg
evince
libreoffice-fresh
inkscape
webcord
signal-desktop
swayimg
swaybg
(writeShellScriptBin "set-background" ''
${swaybg}/bin/swaybg -m fill -i ${./wallpapers/landscapes/tropic_island_day.jpg}
'')
(writeShellScriptBin "protonmail-setup-bridge" ''
pkill -9 -f protonmail-bridge
${protonmail-bridge}/bin/protonmail-bridge -c
swaymsg exec "${protonmail-bridge}/bin/protonmail-bridge -n"
'')
(writeShellScriptBin "davmail-setup" ''
systemctl --user restart davmail # Ensure config file is present
systemctl --user stop davmail
${davmail}/bin/davmail -n ~/.davmail.properties
systemctl --user restart davmail
'')
];
services = {
avizo.enable = true;
gpg-agent.pinentryPackage = pkgs.pinentry-gtk2;
remmina.enable = true;
syncthing.enable = true;
udiskie = {
enable = true;
notify = true;
automount = true;
tray = "never";
};
};
programs.mpv.enable = true;
gtk = with lib.strings; let
accent = "Lavender";
variant = catppuccinVariant;
type =
if variant == "Latte"
then "Light"
else "Dark";
inverseType =
if type == "Light"
then "Dark"
else "Light";
in {
enable = true;
iconTheme = {
package = pkgs.catppuccin-papirus-folders.override {
accent = toLower accent;
flavor = toLower variant;
};
name = "Papirus-Dark";
};
cursorTheme = {
package = pkgs.catppuccin-cursors."${toLower variant}${inverseType}";
name = "Catppuccin-${variant}-${inverseType}-Cursors";
size = 32;
};
theme = let
size = "Standard";
in {
package = pkgs.catppuccin-gtk.override {
accents = [(toLower accent)];
size = toLower size;
variant = toLower variant;
};
name = "Catppuccin-${variant}-${size}-${accent}-${type}";
};
};
xdg = {
mime.enable = true;
mimeApps = let
defaultApplications = import ./mimeapps.nix;
in {
enable = true;
inherit defaultApplications;
associations = {
added = defaultApplications;
removed = {
"x-scheme-handler/zoomus" = config.xdg.mimeApps.defaultApplications."x-scheme-handler/http";
"x-scheme-handler/msteams" = ["teams-for-linux.desktop"];
};
};
};
userDirs = {
enable = true;
createDirectories = true;
extraConfig = {
XDG_PROJECTS_DIR = "${config.home.homeDirectory}/Projects";
};
};
};
xresources.properties = with config.scheme.withHashtag; {
"*background" = base00;
"*foreground" = base05;
"*color0" = base00;
"*color1" = red;
"*color2" = green;
"*color3" = yellow;
"*color4" = blue;
"*color5" = magenta;
"*color6" = cyan;
"*color7" = base04;
"*color8" = base01;
"*color9" = red;
"*color10" = green;
"*color11" = yellow;
"*color12" = blue;
"*color13" = magenta;
"*color14" = cyan;
"*color15" = base05;
};
}