home: move thunar to its own modules with declaratively configured settings in xfconf

This commit is contained in:
Aly Raffauf 2024-04-27 18:34:46 -04:00
parent bb573b8bdc
commit 1c38c91894
4 changed files with 57 additions and 38 deletions

View file

@ -19,6 +19,7 @@
./neofetch ./neofetch
./neovim ./neovim
./tauon ./tauon
./thunar
./thunderbird ./thunderbird
./tmux ./tmux
./vsCodium ./vsCodium

View file

@ -0,0 +1,34 @@
{
pkgs,
lib,
config,
...
}: {
options = {alyraffauf.apps.thunar.enable = lib.mkEnableOption "Enable thunar.";};
config = lib.mkIf config.alyraffauf.apps.thunar.enable {
home.packages = with pkgs; [
xfce.thunar
xfce.thunar-archive-plugin
xfce.thunar-media-tags-plugin
xfce.thunar-volman
xfce.exo
xfce.tumbler
];
xdg.configFile."xfce4/helpers.rc".text = ''
TerminalEmulator=alacritty
FileManager=thunar
WebBrowser=firefox
'';
xfconf.settings = {
thunar = {
"last-menubar-visible" = false;
"misc-confirm-close-multiple-tabs" = false;
"misc-show-delete-action" = true;
"misc-single-click" = true;
};
};
};
}

View file

@ -20,20 +20,27 @@
config = lib.mkIf config.alyraffauf.desktop.hyprland.enable { config = lib.mkIf config.alyraffauf.desktop.hyprland.enable {
# Hypr* modules, plguins, and tools. # Hypr* modules, plguins, and tools.
alyraffauf.desktop.hyprland.hypridle.enable = lib.mkDefault false; alyraffauf = {
alyraffauf.desktop.hyprland.hyprlock.enable = lib.mkDefault false; desktop = {
alyraffauf.desktop.hyprland.hyprpaper.enable = lib.mkDefault true; hyprland = {
alyraffauf.desktop.hyprland.hyprshade.enable = lib.mkDefault true; hypridle.enable = lib.mkDefault false;
hyprlock.enable = lib.mkDefault false;
alyraffauf.desktop.theme.enable = lib.mkDefault true; hyprpaper.enable = lib.mkDefault true;
hyprshade.enable = lib.mkDefault true;
# Basic apps needed to run a hyprland desktop. };
alyraffauf.apps.waybar.enable = lib.mkDefault true; theme.enable = lib.mkDefault true;
alyraffauf.apps.mako.enable = lib.mkDefault true; };
alyraffauf.apps.fuzzel.enable = lib.mkDefault true; apps = {
alyraffauf.apps.wlogout.enable = lib.mkDefault true; # Basic apps needed to run a hyprland desktop.
alyraffauf.apps.alacritty.enable = lib.mkDefault true; alacritty.enable = lib.mkDefault true;
alyraffauf.apps.firefox.enable = lib.mkDefault true; firefox.enable = lib.mkDefault true;
fuzzel.enable = lib.mkDefault true;
mako.enable = lib.mkDefault true;
thunar.enable = lib.mkDefault true;
waybar.enable = lib.mkDefault true;
wlogout.enable = lib.mkDefault true;
};
};
services.cliphist.enable = lib.mkDefault true; services.cliphist.enable = lib.mkDefault true;
@ -48,23 +55,11 @@
hyprshot hyprshot
networkmanagerapplet networkmanagerapplet
trayscale trayscale
xfce.exo
xfce.thunar
xfce.thunar-archive-plugin
xfce.thunar-media-tags-plugin
xfce.thunar-volman
xfce.tumbler
xfce.xfce4-settings xfce.xfce4-settings
xfce.xfce4-taskmanager xfce.xfce4-taskmanager
xfce.xfconf xfce.xfconf
]; ];
xdg.configFile."xfce4/helpers.rc".text = ''
TerminalEmulator=alacritty
FileManager=thunar
WebBrowser=firefox
'';
xdg.portal = { xdg.portal = {
enable = true; enable = true;
configPackages = [pkgs.xdg-desktop-portal-hyprland]; configPackages = [pkgs.xdg-desktop-portal-hyprland];

View file

@ -25,6 +25,7 @@
alacritty.enable = lib.mkDefault true; alacritty.enable = lib.mkDefault true;
firefox.enable = lib.mkDefault true; firefox.enable = lib.mkDefault true;
kanshi.enable = lib.mkDefault true; kanshi.enable = lib.mkDefault true;
thunar.enable = lib.mkDefault true;
}; };
desktop.theme.enable = lib.mkDefault true; desktop.theme.enable = lib.mkDefault true;
}; };
@ -39,12 +40,6 @@
swayidle swayidle
swayosd swayosd
trayscale trayscale
xfce.exo
xfce.thunar
xfce.thunar-archive-plugin
xfce.thunar-media-tags-plugin
xfce.thunar-volman
xfce.tumbler
xfce.xfce4-settings xfce.xfce4-settings
xfce.xfce4-taskmanager xfce.xfce4-taskmanager
xfce.xfconf xfce.xfconf
@ -396,12 +391,6 @@
layer_effects logout_dialog blur enable layer_effects logout_dialog blur enable
''; '';
xdg.configFile."xfce4/helpers.rc".text = ''
TerminalEmulator=alacritty
FileManager=thunar
WebBrowser=firefox
'';
xdg.portal = { xdg.portal = {
enable = true; enable = true;
configPackages = [pkgs.xdg-desktop-portal-wlr]; configPackages = [pkgs.xdg-desktop-portal-wlr];