mirror of
https://github.com/alyraffauf/nixcfg.git
synced 2024-11-22 06:33:56 -05:00
homeManagerModules: simplify and refactor options into options.nix
This commit is contained in:
parent
b01e8ebadb
commit
b3b04a9e41
|
@ -4,28 +4,24 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.apps.alacritty.enable = lib.mkEnableOption "Enables alacritty.";
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.alacritty.enable {
|
||||
programs.alacritty = {
|
||||
enable = true;
|
||||
settings = {
|
||||
colors = {
|
||||
primary = {
|
||||
background = "${config.alyraffauf.desktop.theme.colors.background}";
|
||||
foreground = "${config.alyraffauf.desktop.theme.colors.text}";
|
||||
background = "${config.alyraffauf.theme.colors.background}";
|
||||
foreground = "${config.alyraffauf.theme.colors.text}";
|
||||
};
|
||||
transparent_background_colors = true;
|
||||
draw_bold_text_with_bright_colors = true;
|
||||
};
|
||||
font = {
|
||||
normal = {
|
||||
family = "${config.alyraffauf.desktop.theme.terminalFont.name}";
|
||||
family = "${config.alyraffauf.theme.terminalFont.name}";
|
||||
style = "Regular";
|
||||
};
|
||||
size = config.alyraffauf.desktop.theme.terminalFont.size;
|
||||
size = config.alyraffauf.theme.terminalFont.size;
|
||||
};
|
||||
selection.save_to_clipboard = true;
|
||||
window = {
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.bash.enable = lib.mkEnableOption "Enables bash.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.bash.enable {
|
||||
programs.bash = {
|
||||
enable = true;
|
||||
|
|
|
@ -4,17 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.apps.chromium = {
|
||||
enable = lib.mkEnableOption "Chromium-based browser with default extensions.";
|
||||
package = lib.mkOption {
|
||||
description = "Chromium-based browser (Brave by default).";
|
||||
default = pkgs.brave;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.chromium.enable {
|
||||
programs.chromium = {
|
||||
enable = true;
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.emacs.enable = lib.mkEnableOption "Enables emacs.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.emacs.enable {
|
||||
programs.emacs = {
|
||||
enable = true;
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.eza.enable = lib.mkEnableOption "Enables eza.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.eza.enable {
|
||||
programs.eza = {
|
||||
enable = true;
|
||||
|
|
|
@ -4,10 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.apps.fastfetch.enable = lib.mkEnableOption "Enable fastfetch.";
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.fastfetch.enable {
|
||||
home.packages = [pkgs.fastfetch];
|
||||
xdg.configFile."fastfetch/config.jsonc".source = ./config.jsonc;
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.firefox.enable = lib.mkEnableOption "Enables Firefox.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.firefox.enable {
|
||||
programs.firefox = {enable = true;};
|
||||
};
|
||||
|
|
|
@ -4,18 +4,16 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.fuzzel.enable = lib.mkEnableOption "Enables fuzzel.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.fuzzel.enable {
|
||||
programs.fuzzel = {
|
||||
enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
font = "${config.alyraffauf.desktop.theme.terminalFont.name}:size=${toString config.alyraffauf.desktop.theme.terminalFont.size}";
|
||||
icon-theme = "${config.alyraffauf.desktop.theme.iconTheme.name}";
|
||||
font = "${config.alyraffauf.theme.terminalFont.name}:size=${toString config.alyraffauf.theme.terminalFont.size}";
|
||||
icon-theme = "${config.alyraffauf.theme.iconTheme.name}";
|
||||
layer = "overlay";
|
||||
lines = 3;
|
||||
terminal = config.alyraffauf.desktop.defaultApps.terminal.exe;
|
||||
terminal = config.alyraffauf.defaultApps.terminal.exe;
|
||||
width = 36;
|
||||
};
|
||||
border = {
|
||||
|
@ -23,12 +21,12 @@
|
|||
width = 2;
|
||||
};
|
||||
colors = {
|
||||
background = "${config.alyraffauf.desktop.theme.colors.background}CC";
|
||||
border = "${config.alyraffauf.desktop.theme.colors.primary}EE";
|
||||
selection = "${config.alyraffauf.desktop.theme.colors.background}FF";
|
||||
background = "${config.alyraffauf.theme.colors.background}CC";
|
||||
border = "${config.alyraffauf.theme.colors.primary}EE";
|
||||
selection = "${config.alyraffauf.theme.colors.background}FF";
|
||||
selection-match = "#e78284FF";
|
||||
selection-text = "#f4b8e4FF";
|
||||
text = "${config.alyraffauf.desktop.theme.colors.text}FF";
|
||||
text = "${config.alyraffauf.theme.colors.text}FF";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.fzf.enable = lib.mkEnableOption "Enables fzf.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.fzf.enable {
|
||||
programs.fzf = {
|
||||
enable = true;
|
||||
|
|
|
@ -4,10 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.apps.librewolf.enable = lib.mkEnableOption "Enables librewolf.";
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.librewolf.enable {
|
||||
programs.librewolf = {
|
||||
enable = true;
|
||||
|
|
|
@ -4,22 +4,20 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.mako.enable = lib.mkEnableOption "Mako notification daemon.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.mako.enable {
|
||||
services.mako = {
|
||||
enable = true;
|
||||
anchor = "top-center";
|
||||
backgroundColor = "${config.alyraffauf.desktop.theme.colors.background}CC";
|
||||
borderColor = "${config.alyraffauf.desktop.theme.colors.primary}EE";
|
||||
backgroundColor = "${config.alyraffauf.theme.colors.background}CC";
|
||||
borderColor = "${config.alyraffauf.theme.colors.primary}EE";
|
||||
borderSize = 2;
|
||||
borderRadius = 10;
|
||||
defaultTimeout = 10000;
|
||||
font = "${config.alyraffauf.desktop.theme.font.name} Regular ${toString config.alyraffauf.desktop.theme.font.size}";
|
||||
font = "${config.alyraffauf.theme.font.name} Regular ${toString config.alyraffauf.theme.font.size}";
|
||||
height = 300;
|
||||
layer = "top";
|
||||
padding = "15";
|
||||
textColor = "${config.alyraffauf.desktop.theme.colors.text}";
|
||||
textColor = "${config.alyraffauf.theme.colors.text}";
|
||||
width = 400;
|
||||
margin = "20,0";
|
||||
extraConfig = ''
|
||||
|
|
|
@ -4,10 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.apps.neofetch.enable = lib.mkEnableOption "Enable neofetch.";
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.neofetch.enable {
|
||||
home.packages = [pkgs.neofetch];
|
||||
xdg.configFile."neofetch/config.conf".source = ./config.conf;
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.neovim.enable = lib.mkEnableOption "Enables neovim.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.neovim.enable {
|
||||
programs.neovim = {
|
||||
enable = true;
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.swaylock.enable = lib.mkEnableOption "Enable Swaylock.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.swaylock.enable {
|
||||
home.packages = with pkgs; [swaylock];
|
||||
|
||||
|
@ -17,8 +15,8 @@
|
|||
caps-lock-key-hl-color=e78284
|
||||
color=303446
|
||||
daemonize
|
||||
font="${config.alyraffauf.desktop.theme.terminalFont.name}-Regular"
|
||||
image=${config.alyraffauf.desktop.theme.wallpaper}
|
||||
font="${config.alyraffauf.theme.terminalFont.name}-Regular"
|
||||
image=${config.alyraffauf.theme.wallpaper}
|
||||
indicator-caps-lock
|
||||
indicator-idle-visible
|
||||
indicator-radius=120
|
||||
|
@ -29,17 +27,17 @@
|
|||
inside-ver-color=303446cc
|
||||
inside-wrong-color=303446cc
|
||||
key-hl-color=a6d189
|
||||
line-caps-lock-color=${config.alyraffauf.desktop.theme.colors.background}CC
|
||||
line-clear-color=${config.alyraffauf.desktop.theme.colors.background}CC
|
||||
line-color=${config.alyraffauf.desktop.theme.colors.background}CC
|
||||
line-ver-color=${config.alyraffauf.desktop.theme.colors.background}CC
|
||||
line-wrong-color=${config.alyraffauf.desktop.theme.colors.background}CC
|
||||
line-caps-lock-color=${config.alyraffauf.theme.colors.background}CC
|
||||
line-clear-color=${config.alyraffauf.theme.colors.background}CC
|
||||
line-color=${config.alyraffauf.theme.colors.background}CC
|
||||
line-ver-color=${config.alyraffauf.theme.colors.background}CC
|
||||
line-wrong-color=${config.alyraffauf.theme.colors.background}CC
|
||||
ring-caps-lock-color=e78284cc
|
||||
ring-clear-color=85c1dccc
|
||||
ring-color=${config.alyraffauf.desktop.theme.colors.primary}CC
|
||||
ring-color=${config.alyraffauf.theme.colors.primary}CC
|
||||
ring-ver-color=a6d189cc
|
||||
ring-wrong-color=e78284cc
|
||||
separator-color=${config.alyraffauf.desktop.theme.colors.background}CC
|
||||
separator-color=${config.alyraffauf.theme.colors.background}CC
|
||||
text-caps-lock-color=c6d0f5
|
||||
text-clear-color=c6d0f5
|
||||
text-ver-color=c6d0f5
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.thunar.enable = lib.mkEnableOption "Enable thunar.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.thunar.enable {
|
||||
home.packages = with pkgs; [
|
||||
xfce.thunar
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.tmux.enable = lib.mkEnableOption "Enables tmux.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.tmux.enable {
|
||||
programs.tmux = {
|
||||
enable = true;
|
||||
|
|
|
@ -4,10 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.apps.vsCodium.enable = lib.mkEnableOption "Enables VSCodium.";
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.vsCodium.enable {
|
||||
alyraffauf.apps.alacritty.enable = lib.mkDefault true;
|
||||
|
||||
|
@ -18,22 +14,22 @@
|
|||
enableExtensionUpdateCheck = false;
|
||||
userSettings = {
|
||||
"diffEditor.ignoreTrimWhitespace" = false;
|
||||
"editor.fontFamily" = "'NotoSansM Nerd Font','${config.alyraffauf.desktop.theme.terminalFont.name}', 'monospace', monospace";
|
||||
"editor.fontFamily" = "'NotoSansM Nerd Font','${config.alyraffauf.theme.terminalFont.name}', 'monospace', monospace";
|
||||
"explorer.confirmDelete" = false;
|
||||
"files.autoSave" = "afterDelay";
|
||||
"git.autofetch" = true;
|
||||
"git.confirmSync" = false;
|
||||
"nix.formatterPath" = lib.getExe pkgs.alejandra;
|
||||
"terminal.external.linuxExec" = config.alyraffauf.desktop.defaultApps.terminal.exe;
|
||||
"terminal.external.linuxExec" = config.alyraffauf.defaultApps.terminal.exe;
|
||||
"update.mode" = "none";
|
||||
"window.menuBarVisibility" = "hidden";
|
||||
"window.zoomPerWindow" = false;
|
||||
"workbench.colorTheme" =
|
||||
if config.alyraffauf.desktop.theme.colors.preferDark
|
||||
if config.alyraffauf.theme.colors.preferDark
|
||||
then "Catppuccin Frappé"
|
||||
else "Catppuccin Latte";
|
||||
"workbench.iconTheme" =
|
||||
if config.alyraffauf.desktop.theme.colors.preferDark
|
||||
if config.alyraffauf.theme.colors.preferDark
|
||||
then "catppuccin-frappe"
|
||||
else "catppuccin-latte";
|
||||
"workbench.preferredDarkColorTheme" = "Catppuccin Frappé";
|
||||
|
|
|
@ -4,32 +4,30 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.waybar.enable = lib.mkEnableOption "Enables waybar.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.waybar.enable {
|
||||
xdg.configFile."waybar/style.css".text = ''
|
||||
* {
|
||||
border: none;
|
||||
border-radius: 0;
|
||||
font-family: "${config.alyraffauf.desktop.theme.terminalFont.name}";
|
||||
font-family: "${config.alyraffauf.theme.terminalFont.name}";
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
window#waybar {
|
||||
background: rgba (35, 38, 52, 0.0);
|
||||
color: ${config.alyraffauf.desktop.theme.colors.text};
|
||||
color: ${config.alyraffauf.theme.colors.text};
|
||||
}
|
||||
|
||||
#workspaces button {
|
||||
padding: 0px 5px;
|
||||
margin: 0 0px;
|
||||
color: ${config.alyraffauf.desktop.theme.colors.text};
|
||||
color: ${config.alyraffauf.theme.colors.text};
|
||||
}
|
||||
|
||||
#workspaces button.active,
|
||||
#workspaces button.focused {
|
||||
color: ${config.alyraffauf.desktop.theme.colors.primary};
|
||||
color: ${config.alyraffauf.theme.colors.primary};
|
||||
}
|
||||
|
||||
#submap,
|
||||
|
@ -42,11 +40,11 @@
|
|||
#tags button {
|
||||
padding: 0px 5px;
|
||||
margin: 0 0px;
|
||||
color: ${config.alyraffauf.desktop.theme.colors.text};
|
||||
color: ${config.alyraffauf.theme.colors.text};
|
||||
}
|
||||
|
||||
#tags button.focused {
|
||||
color: ${config.alyraffauf.desktop.theme.colors.primary};
|
||||
color: ${config.alyraffauf.theme.colors.primary};
|
||||
}
|
||||
|
||||
#clock,
|
||||
|
@ -66,11 +64,11 @@
|
|||
}
|
||||
|
||||
#battery {
|
||||
color: ${config.alyraffauf.desktop.theme.colors.text};
|
||||
color: ${config.alyraffauf.theme.colors.text};
|
||||
}
|
||||
|
||||
#battery.charging {
|
||||
color: ${config.alyraffauf.desktop.theme.colors.primary};
|
||||
color: ${config.alyraffauf.theme.colors.primary};
|
||||
}
|
||||
|
||||
#battery.critical:not(.charging) {
|
||||
|
@ -89,7 +87,7 @@
|
|||
#hardware {
|
||||
border-radius: 10;
|
||||
background: rgba ${
|
||||
if config.alyraffauf.desktop.theme.colors.preferDark
|
||||
if config.alyraffauf.theme.colors.preferDark
|
||||
then "(35, 38, 52, 0.8);"
|
||||
else "(220, 224, 232, 0.8);"
|
||||
}
|
||||
|
@ -103,7 +101,7 @@
|
|||
|
||||
#submap,
|
||||
#mode {
|
||||
color: ${config.alyraffauf.desktop.theme.colors.text};
|
||||
color: ${config.alyraffauf.theme.colors.text};
|
||||
background: rgba(231, 130, 132, 0.8);
|
||||
}
|
||||
'';
|
||||
|
@ -232,7 +230,7 @@
|
|||
"tooltip-format-wifi" = "{essid} ({signalStrength}%) {icon}";
|
||||
"tooltip-format-ethernet" = "{ifname} ";
|
||||
"tooltip-format-disconnected" = "Disconnected";
|
||||
"on-click" = "${config.alyraffauf.desktop.defaultApps.terminalEditor.exe} --class nmtui -e ${pkgs.networkmanager}/bin/nmtui";
|
||||
"on-click" = "${config.alyraffauf.defaultApps.terminalEditor.exe} --class nmtui -e ${pkgs.networkmanager}/bin/nmtui";
|
||||
};
|
||||
"tray" = {"spacing" = 15;};
|
||||
"custom/logout" = {
|
||||
|
|
|
@ -4,8 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {alyraffauf.apps.wlogout.enable = lib.mkEnableOption "Enables wlogout.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.apps.wlogout.enable {
|
||||
programs.wlogout = {
|
||||
enable = true;
|
||||
|
@ -31,7 +29,7 @@
|
|||
];
|
||||
style = ''
|
||||
* {
|
||||
font-family: "${config.alyraffauf.desktop.theme.font.name}", sans-serif;
|
||||
font-family: "${config.alyraffauf.theme.font.name}", sans-serif;
|
||||
background-image: none;
|
||||
box-shadow: none;
|
||||
transition: 20ms;
|
||||
|
@ -44,7 +42,7 @@
|
|||
button {
|
||||
text-decoration-color: #FAFAFA;
|
||||
color: #FAFAFA;
|
||||
background-color: ${config.alyraffauf.desktop.theme.colors.background};
|
||||
background-color: ${config.alyraffauf.theme.colors.background};
|
||||
background-color: rgba(12, 12, 12, 0.0);
|
||||
background-repeat: no-repeat;
|
||||
background-size: 10%;
|
||||
|
@ -52,7 +50,7 @@
|
|||
}
|
||||
|
||||
button:active, button:hover {
|
||||
background-color: ${config.alyraffauf.desktop.theme.colors.primary};
|
||||
background-color: ${config.alyraffauf.theme.colors.primary};
|
||||
outline-style: none;
|
||||
}
|
||||
|
||||
|
|
|
@ -4,7 +4,15 @@ inputs: self: {
|
|||
lib,
|
||||
...
|
||||
}: {
|
||||
imports = [./apps ./desktop ./services ./scripts];
|
||||
imports = [
|
||||
./apps
|
||||
./defaultApps.nix
|
||||
./desktop
|
||||
./options.nix
|
||||
./scripts
|
||||
./services
|
||||
./theme.nix
|
||||
];
|
||||
|
||||
nixpkgs = {
|
||||
config = {
|
||||
|
|
48
homeManagerModules/defaultApps.nix
Normal file
48
homeManagerModules/defaultApps.nix
Normal file
|
@ -0,0 +1,48 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf config.alyraffauf.defaultApps.enable {
|
||||
home.packages = with config.alyraffauf.defaultApps; [
|
||||
audioPlayer.package
|
||||
editor.package
|
||||
imageViewer.package
|
||||
pdfEditor.package
|
||||
terminalEditor.package
|
||||
videoPlayer.package
|
||||
webBrowser.package
|
||||
];
|
||||
xdg.mimeApps = {
|
||||
enable = true;
|
||||
defaultApplications = {
|
||||
"application/pdf" = config.alyraffauf.defaultApps.pdfEditor.desktop;
|
||||
"application/x-shellscript" = config.alyraffauf.defaultApps.editor.desktop;
|
||||
"application/xhtml+xml" = config.alyraffauf.defaultApps.webBrowser.desktop;
|
||||
"audio/flac" = config.alyraffauf.defaultApps.audioPlayer.desktop;
|
||||
"audio/mpeg" = config.alyraffauf.defaultApps.audioPlayer.desktop;
|
||||
"audio/opus" = config.alyraffauf.defaultApps.audioPlayer.desktop;
|
||||
"image/jpeg" = config.alyraffauf.defaultApps.imageViewer.desktop;
|
||||
"image/png" = config.alyraffauf.defaultApps.imageViewer.desktop;
|
||||
"text/html" = config.alyraffauf.defaultApps.webBrowser.desktop;
|
||||
"text/plain" = config.alyraffauf.defaultApps.editor.desktop;
|
||||
"text/x-python" = config.alyraffauf.defaultApps.editor.desktop;
|
||||
"text/xml" = config.alyraffauf.defaultApps.webBrowser.desktop;
|
||||
"video/H264" = config.alyraffauf.defaultApps.videoPlayer.desktop;
|
||||
"video/mp4" = config.alyraffauf.defaultApps.videoPlayer.desktop;
|
||||
"video/mpeg" = config.alyraffauf.defaultApps.videoPlayer.desktop;
|
||||
"video/ogg" = config.alyraffauf.defaultApps.videoPlayer.desktop;
|
||||
"video/x-matroska" = config.alyraffauf.defaultApps.videoPlayer.desktop;
|
||||
"x-scheme-handler/ftp" = config.alyraffauf.defaultApps.webBrowser.desktop;
|
||||
"x-scheme-handler/http" = config.alyraffauf.defaultApps.webBrowser.desktop;
|
||||
"x-scheme-handler/https" = config.alyraffauf.defaultApps.webBrowser.desktop;
|
||||
};
|
||||
};
|
||||
home.sessionVariables = {
|
||||
BROWSER = "${config.alyraffauf.defaultApps.webBrowser.exe}";
|
||||
EDITOR = "${config.alyraffauf.defaultApps.terminalEditor.exe}";
|
||||
TERMINAL = "${config.alyraffauf.defaultApps.terminal.exe}";
|
||||
};
|
||||
};
|
||||
}
|
|
@ -4,35 +4,30 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.desktop.cinnamon.enable =
|
||||
lib.mkEnableOption "Cinnamon with sane defaults.";
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.desktop.cinnamon.enable {
|
||||
dconf.enable = true;
|
||||
dconf.settings = {
|
||||
"org/cinnamon/desktop/background".picture-uri = "file://${config.alyraffauf.desktop.theme.wallpaper}";
|
||||
"org/cinnamon/desktop/interface".cursor-size = config.alyraffauf.desktop.theme.cursorTheme.size;
|
||||
"org/cinnamon/desktop/interface".cursor-theme = config.alyraffauf.desktop.theme.cursorTheme.name;
|
||||
"org/cinnamon/desktop/interface".font-name = "${config.alyraffauf.desktop.theme.font.name} Regular ${toString config.alyraffauf.desktop.theme.font.size}";
|
||||
"org/cinnamon/desktop/interface".gtk-theme = config.alyraffauf.desktop.theme.gtk.name;
|
||||
"org/cinnamon/desktop/interface".icon-theme = config.alyraffauf.desktop.theme.iconTheme.name;
|
||||
"org/cinnamon/desktop/wm/preferences".titlebar-font = "${config.alyraffauf.desktop.theme.font.name} ${toString config.alyraffauf.desktop.theme.font.size}";
|
||||
"org/cinnamon/desktop/background".picture-uri = "file://${config.alyraffauf.theme.wallpaper}";
|
||||
"org/cinnamon/desktop/interface".cursor-size = config.alyraffauf.theme.cursorTheme.size;
|
||||
"org/cinnamon/desktop/interface".cursor-theme = config.alyraffauf.theme.cursorTheme.name;
|
||||
"org/cinnamon/desktop/interface".font-name = "${config.alyraffauf.theme.font.name} Regular ${toString config.alyraffauf.theme.font.size}";
|
||||
"org/cinnamon/desktop/interface".gtk-theme = config.alyraffauf.theme.gtk.name;
|
||||
"org/cinnamon/desktop/interface".icon-theme = config.alyraffauf.theme.iconTheme.name;
|
||||
"org/cinnamon/desktop/wm/preferences".titlebar-font = "${config.alyraffauf.theme.font.name} ${toString config.alyraffauf.theme.font.size}";
|
||||
"org/cinnamon/gestures".enabled = true;
|
||||
"org/cinnamon/muffin".workspace-cycle = true;
|
||||
"org/cinnamon/muffin".workspaces-only-on-primary = true;
|
||||
"org/cinnamon/settings-daemon/peripherals/touchscreen".orientation-lock = false;
|
||||
"org/cinnamon/theme".name = config.alyraffauf.desktop.theme.gtk.name;
|
||||
"org/gnome/desktop/interface".gtk-theme = config.alyraffauf.desktop.theme.gtk.name;
|
||||
"org/gnome/desktop/interface".cursor-size = config.alyraffauf.desktop.theme.cursorTheme.size;
|
||||
"org/gnome/desktop/interface".cursor-theme = config.alyraffauf.desktop.theme.cursorTheme.name;
|
||||
"org/gnome/desktop/interface".icon-theme = config.alyraffauf.desktop.theme.iconTheme.name;
|
||||
"org/gnome/desktop/interface".monospace-font-name = "${config.alyraffauf.desktop.theme.terminalFont.name} Regular ${toString config.alyraffauf.desktop.theme.terminalFont.size}";
|
||||
"org/cinnamon/theme".name = config.alyraffauf.theme.gtk.name;
|
||||
"org/gnome/desktop/interface".gtk-theme = config.alyraffauf.theme.gtk.name;
|
||||
"org/gnome/desktop/interface".cursor-size = config.alyraffauf.theme.cursorTheme.size;
|
||||
"org/gnome/desktop/interface".cursor-theme = config.alyraffauf.theme.cursorTheme.name;
|
||||
"org/gnome/desktop/interface".icon-theme = config.alyraffauf.theme.iconTheme.name;
|
||||
"org/gnome/desktop/interface".monospace-font-name = "${config.alyraffauf.theme.terminalFont.name} Regular ${toString config.alyraffauf.theme.terminalFont.size}";
|
||||
"org/gnome/desktop/peripherals/touchpad".natural-scroll = true;
|
||||
"org/gnome/desktop/peripherals/touchpad".tap-to-click = true;
|
||||
"org/gnome/desktop/wm/preferences".titlebar-font = "${config.alyraffauf.desktop.theme.font.name} ${toString config.alyraffauf.desktop.theme.font.size}";
|
||||
"org/nemo/desktop".font = "${config.alyraffauf.desktop.theme.font.name} ${toString config.alyraffauf.desktop.theme.font.size}";
|
||||
"org/gnome/desktop/wm/preferences".titlebar-font = "${config.alyraffauf.theme.font.name} ${toString config.alyraffauf.theme.font.size}";
|
||||
"org/nemo/desktop".font = "${config.alyraffauf.theme.font.name} ${toString config.alyraffauf.theme.font.size}";
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -6,11 +6,9 @@
|
|||
}: {
|
||||
imports = [
|
||||
./cinnamon
|
||||
./defaultApps.nix
|
||||
./gnome
|
||||
./hyprland
|
||||
./sway
|
||||
./theme.nix
|
||||
./waylandComp.nix
|
||||
];
|
||||
}
|
||||
|
|
|
@ -1,191 +0,0 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.desktop.defaultApps = {
|
||||
enable =
|
||||
lib.mkEnableOption "GTK and Qt themes.";
|
||||
webBrowser = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default web browser executable name.";
|
||||
default = lib.getExe config.alyraffauf.desktop.defaultApps.webBrowser.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default web browser desktop file name.";
|
||||
default = "firefox.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default web browser package.";
|
||||
default = config.programs.firefox.package;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
editor = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default editor executable name.";
|
||||
default = lib.getExe config.alyraffauf.desktop.defaultApps.editor.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default editor desktop file name.";
|
||||
default = "codium.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default editor package.";
|
||||
default = config.programs.vscode.package;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
terminalEditor = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default terminal editor executable name.";
|
||||
default = lib.getExe config.alyraffauf.desktop.defaultApps.terminalEditor.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default terminal editor desktop file name.";
|
||||
default = "nvim.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default terminal editor package.";
|
||||
default = config.programs.neovim.package;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
terminal = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default terminal executable name.";
|
||||
default = lib.getExe config.alyraffauf.desktop.defaultApps.terminal.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default terminal desktop file name.";
|
||||
default = "alacritty.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default terminal package.";
|
||||
default = config.programs.alacritty.package;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
pdfEditor = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default PDF editor executable name.";
|
||||
default = lib.getExe config.alyraffauf.desktop.defaultApps.pdfEditor.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default PDF Editor desktop file name.";
|
||||
default = "org.gnome.Evince.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default PDF Editor package.";
|
||||
default = pkgs.evince;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
imageViewer = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default image viewer executable name.";
|
||||
default = lib.getExe config.alyraffauf.desktop.defaultApps.imageViewer.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default image viewer desktop file name.";
|
||||
default = "org.gnome.eog.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default image viewer package.";
|
||||
default = pkgs.gnome.eog;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
videoPlayer = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default video player executable name.";
|
||||
default = lib.getExe config.alyraffauf.desktop.defaultApps.videoPlayer.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default video player desktop file name.";
|
||||
default = "io.github.celluloid_player.Celluloid.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default video player package.";
|
||||
default = pkgs.celluloid;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
audioPlayer = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default audio player executable name.";
|
||||
default = lib.getExe config.alyraffauf.desktop.defaultApps.audioPlayer.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default audio player desktop file name.";
|
||||
default = config.alyraffauf.desktop.defaultApps.videoPlayer.desktop;
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default audio player package.";
|
||||
default = config.alyraffauf.desktop.defaultApps.videoPlayer.package;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.desktop.defaultApps.enable {
|
||||
home.packages = with config.alyraffauf.desktop.defaultApps; [
|
||||
audioPlayer.package
|
||||
editor.package
|
||||
imageViewer.package
|
||||
pdfEditor.package
|
||||
terminalEditor.package
|
||||
videoPlayer.package
|
||||
webBrowser.package
|
||||
];
|
||||
xdg.mimeApps = {
|
||||
enable = true;
|
||||
defaultApplications = {
|
||||
"application/pdf" = config.alyraffauf.desktop.defaultApps.pdfEditor.desktop;
|
||||
"application/x-shellscript" = config.alyraffauf.desktop.defaultApps.editor.desktop;
|
||||
"application/xhtml+xml" = config.alyraffauf.desktop.defaultApps.webBrowser.desktop;
|
||||
"audio/flac" = config.alyraffauf.desktop.defaultApps.audioPlayer.desktop;
|
||||
"audio/mpeg" = config.alyraffauf.desktop.defaultApps.audioPlayer.desktop;
|
||||
"audio/opus" = config.alyraffauf.desktop.defaultApps.audioPlayer.desktop;
|
||||
"image/jpeg" = config.alyraffauf.desktop.defaultApps.imageViewer.desktop;
|
||||
"image/png" = config.alyraffauf.desktop.defaultApps.imageViewer.desktop;
|
||||
"text/html" = config.alyraffauf.desktop.defaultApps.webBrowser.desktop;
|
||||
"text/plain" = config.alyraffauf.desktop.defaultApps.editor.desktop;
|
||||
"text/x-python" = config.alyraffauf.desktop.defaultApps.editor.desktop;
|
||||
"text/xml" = config.alyraffauf.desktop.defaultApps.webBrowser.desktop;
|
||||
"video/H264" = config.alyraffauf.desktop.defaultApps.videoPlayer.desktop;
|
||||
"video/mp4" = config.alyraffauf.desktop.defaultApps.videoPlayer.desktop;
|
||||
"video/mpeg" = config.alyraffauf.desktop.defaultApps.videoPlayer.desktop;
|
||||
"video/ogg" = config.alyraffauf.desktop.defaultApps.videoPlayer.desktop;
|
||||
"video/x-matroska" = config.alyraffauf.desktop.defaultApps.videoPlayer.desktop;
|
||||
"x-scheme-handler/ftp" = config.alyraffauf.desktop.defaultApps.webBrowser.desktop;
|
||||
"x-scheme-handler/http" = config.alyraffauf.desktop.defaultApps.webBrowser.desktop;
|
||||
"x-scheme-handler/https" = config.alyraffauf.desktop.defaultApps.webBrowser.desktop;
|
||||
};
|
||||
};
|
||||
home.sessionVariables = {
|
||||
BROWSER = "${config.alyraffauf.desktop.defaultApps.webBrowser.exe}";
|
||||
EDITOR = "${config.alyraffauf.desktop.defaultApps.terminalEditor.exe}";
|
||||
TERMINAL = "${config.alyraffauf.desktop.defaultApps.terminal.exe}";
|
||||
};
|
||||
};
|
||||
}
|
|
@ -4,11 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.desktop.gnome.enable =
|
||||
lib.mkEnableOption "Enables GNOME with basic settings configuration.";
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.desktop.gnome.enable {
|
||||
dconf.enable = true;
|
||||
dconf.settings = {
|
||||
|
|
|
@ -4,46 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.desktop.hyprland = {
|
||||
enable =
|
||||
lib.mkEnableOption "Enables hyprland with extra apps.";
|
||||
autoSuspend = lib.mkOption {
|
||||
description = "Whether to autosuspend on idle.";
|
||||
default = config.alyraffauf.desktop.hyprland.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
randomWallpaper = lib.mkOption {
|
||||
description = "Whether to enable random wallpaper script.";
|
||||
default = config.alyraffauf.desktop.hyprland.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
redShift = lib.mkOption {
|
||||
description = "Whether to redshift display colors at night.";
|
||||
default = config.alyraffauf.desktop.hyprland.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
tabletMode = {
|
||||
enable = lib.mkEnableOption "Tablet mode for hyprland.";
|
||||
autoRotate = lib.mkOption {
|
||||
description = "Whether to autorotate screen.";
|
||||
default = config.alyraffauf.desktop.hyprland.tabletMode.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
menuButton = lib.mkOption {
|
||||
description = "Whether to add menu button for waybar.";
|
||||
default = config.alyraffauf.desktop.hyprland.tabletMode.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
virtKeyboard = lib.mkOption {
|
||||
description = "Whether to enable dynamic virtual keyboard.";
|
||||
default = config.alyraffauf.desktop.hyprland.tabletMode.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.desktop.hyprland.enable {
|
||||
alyraffauf = {
|
||||
desktop = {
|
||||
|
@ -79,14 +39,14 @@
|
|||
|
||||
# Default apps
|
||||
defaultApps = {
|
||||
browser = config.alyraffauf.desktop.defaultApps.webBrowser.exe;
|
||||
editor = config.alyraffauf.desktop.defaultApps.editor.exe;
|
||||
browser = config.alyraffauf.defaultApps.webBrowser.exe;
|
||||
editor = config.alyraffauf.defaultApps.editor.exe;
|
||||
fileManager = lib.getExe pkgs.xfce.thunar;
|
||||
launcher = lib.getExe pkgs.fuzzel;
|
||||
lock = lib.getExe pkgs.swaylock;
|
||||
logout = lib.getExe pkgs.wlogout;
|
||||
passwordManager = lib.getExe' pkgs.keepassxc "keepassxc";
|
||||
terminal = config.alyraffauf.desktop.defaultApps.terminal.exe;
|
||||
terminal = config.alyraffauf.defaultApps.terminal.exe;
|
||||
virtKeyboard = lib.getExe' pkgs.squeekboard "squeekboard";
|
||||
};
|
||||
|
||||
|
@ -119,7 +79,7 @@
|
|||
done
|
||||
fi
|
||||
''
|
||||
else "${lib.getExe pkgs.swaybg} -i ${config.alyraffauf.desktop.theme.wallpaper}";
|
||||
else "${lib.getExe pkgs.swaybg} -i ${config.alyraffauf.theme.wallpaper}";
|
||||
|
||||
startupApps =
|
||||
[
|
||||
|
@ -268,7 +228,7 @@
|
|||
env = GDK_SCALE,${gdk_scale}
|
||||
|
||||
# Some default env vars.
|
||||
env = XCURSOR_SIZE,${toString config.alyraffauf.desktop.theme.cursorTheme.size}
|
||||
env = XCURSOR_SIZE,${toString config.alyraffauf.theme.cursorTheme.size}
|
||||
env = QT_QPA_PLATFORMTHEME,qt6ct
|
||||
|
||||
# Execute necessary apps
|
||||
|
@ -303,8 +263,8 @@
|
|||
gaps_in = 5
|
||||
gaps_out = 6
|
||||
border_size = 2
|
||||
col.active_border = rgba(${lib.strings.removePrefix "#" config.alyraffauf.desktop.theme.colors.secondary}EE) rgba(${lib.strings.removePrefix "#" config.alyraffauf.desktop.theme.colors.primary}EE) 45deg
|
||||
col.inactive_border = rgba(${lib.strings.removePrefix "#" config.alyraffauf.desktop.theme.colors.inactive}AA)
|
||||
col.active_border = rgba(${lib.strings.removePrefix "#" config.alyraffauf.theme.colors.secondary}EE) rgba(${lib.strings.removePrefix "#" config.alyraffauf.theme.colors.primary}EE) 45deg
|
||||
col.inactive_border = rgba(${lib.strings.removePrefix "#" config.alyraffauf.theme.colors.inactive}AA)
|
||||
|
||||
layout = dwindle
|
||||
|
||||
|
@ -321,7 +281,7 @@
|
|||
drop_shadow = yes
|
||||
shadow_range = 4
|
||||
shadow_render_power = 3
|
||||
col.shadow = rgba(${lib.strings.removePrefix "#" config.alyraffauf.desktop.theme.colors.shadow}EE)
|
||||
col.shadow = rgba(${lib.strings.removePrefix "#" config.alyraffauf.theme.colors.shadow}EE)
|
||||
|
||||
dim_special = 0.5
|
||||
|
||||
|
|
|
@ -48,7 +48,7 @@
|
|||
wayland.windowManager.sway.wrapperFeatures.gtk = true;
|
||||
wayland.windowManager.sway.checkConfig = false;
|
||||
|
||||
alyraffauf.desktop.theme.gtk.hideTitleBar =
|
||||
alyraffauf.theme.gtk.hideTitleBar =
|
||||
if config.wayland.windowManager.sway.package == pkgs.sway
|
||||
then true
|
||||
else false;
|
||||
|
@ -58,10 +58,10 @@
|
|||
swaymsg = lib.getExe' config.wayland.windowManager.sway.package "swaymsg";
|
||||
|
||||
# Default apps
|
||||
browser = config.alyraffauf.desktop.defaultApps.webBrowser.exe;
|
||||
browser = config.alyraffauf.defaultApps.webBrowser.exe;
|
||||
fileManager = lib.getExe pkgs.xfce.thunar;
|
||||
editor = config.alyraffauf.desktop.defaultApps.editor.exe;
|
||||
terminal = config.alyraffauf.desktop.defaultApps.terminal.exe;
|
||||
editor = config.alyraffauf.defaultApps.editor.exe;
|
||||
terminal = config.alyraffauf.defaultApps.terminal.exe;
|
||||
|
||||
brightness = lib.getExe' pkgs.swayosd "swayosd-client";
|
||||
brightness_up = "${brightness} --brightness=raise";
|
||||
|
@ -80,7 +80,7 @@
|
|||
bar = lib.getExe pkgs.waybar;
|
||||
launcher = lib.getExe pkgs.fuzzel;
|
||||
notifyd = lib.getExe pkgs.mako;
|
||||
wallpaperd = "${lib.getExe pkgs.swaybg} -i ${config.alyraffauf.desktop.theme.wallpaper}";
|
||||
wallpaperd = "${lib.getExe pkgs.swaybg} -i ${config.alyraffauf.theme.wallpaper}";
|
||||
logout = lib.getExe pkgs.wlogout;
|
||||
lock = lib.getExe pkgs.swaylock;
|
||||
idled = pkgs.writeShellScript "sway-idled" ''
|
||||
|
@ -121,27 +121,27 @@
|
|||
in {
|
||||
bars = [{command = "${bar}";}];
|
||||
modifier = "${modifier}";
|
||||
colors.background = "${config.alyraffauf.desktop.theme.colors.primary}EE";
|
||||
colors.background = "${config.alyraffauf.theme.colors.primary}EE";
|
||||
colors.focused = {
|
||||
background = "${config.alyraffauf.desktop.theme.colors.primary}EE";
|
||||
border = "${config.alyraffauf.desktop.theme.colors.primary}EE";
|
||||
childBorder = "${config.alyraffauf.desktop.theme.colors.primary}EE";
|
||||
indicator = "${config.alyraffauf.desktop.theme.colors.primary}EE";
|
||||
text = "${config.alyraffauf.desktop.theme.colors.text}";
|
||||
background = "${config.alyraffauf.theme.colors.primary}EE";
|
||||
border = "${config.alyraffauf.theme.colors.primary}EE";
|
||||
childBorder = "${config.alyraffauf.theme.colors.primary}EE";
|
||||
indicator = "${config.alyraffauf.theme.colors.primary}EE";
|
||||
text = "${config.alyraffauf.theme.colors.text}";
|
||||
};
|
||||
colors.focusedInactive = {
|
||||
background = "${config.alyraffauf.desktop.theme.colors.inactive}AA";
|
||||
border = "${config.alyraffauf.desktop.theme.colors.inactive}AA";
|
||||
childBorder = "${config.alyraffauf.desktop.theme.colors.inactive}AA";
|
||||
indicator = "${config.alyraffauf.desktop.theme.colors.inactive}AA";
|
||||
text = "${config.alyraffauf.desktop.theme.colors.text}";
|
||||
background = "${config.alyraffauf.theme.colors.inactive}AA";
|
||||
border = "${config.alyraffauf.theme.colors.inactive}AA";
|
||||
childBorder = "${config.alyraffauf.theme.colors.inactive}AA";
|
||||
indicator = "${config.alyraffauf.theme.colors.inactive}AA";
|
||||
text = "${config.alyraffauf.theme.colors.text}";
|
||||
};
|
||||
colors.unfocused = {
|
||||
background = "${config.alyraffauf.desktop.theme.colors.inactive}AA";
|
||||
border = "${config.alyraffauf.desktop.theme.colors.inactive}AA";
|
||||
childBorder = "${config.alyraffauf.desktop.theme.colors.inactive}AA";
|
||||
indicator = "${config.alyraffauf.desktop.theme.colors.inactive}AA";
|
||||
text = "${config.alyraffauf.desktop.theme.colors.text}";
|
||||
background = "${config.alyraffauf.theme.colors.inactive}AA";
|
||||
border = "${config.alyraffauf.theme.colors.inactive}AA";
|
||||
childBorder = "${config.alyraffauf.theme.colors.inactive}AA";
|
||||
indicator = "${config.alyraffauf.theme.colors.inactive}AA";
|
||||
text = "${config.alyraffauf.theme.colors.text}";
|
||||
};
|
||||
defaultWorkspace = "workspace number 1";
|
||||
focus = {
|
||||
|
@ -150,9 +150,9 @@
|
|||
# mouseWarping = "container";
|
||||
};
|
||||
fonts = {
|
||||
names = ["${config.alyraffauf.desktop.theme.font.name}"];
|
||||
names = ["${config.alyraffauf.theme.font.name}"];
|
||||
style = "Bold";
|
||||
size = config.alyraffauf.desktop.theme.font.size + 0.0;
|
||||
size = config.alyraffauf.theme.font.size + 0.0;
|
||||
};
|
||||
gaps.inner = 5;
|
||||
gaps.outer = 5;
|
||||
|
@ -459,7 +459,7 @@
|
|||
corner_radius 10
|
||||
shadows enable
|
||||
shadows_on_csd enable
|
||||
shadow_color ${config.alyraffauf.desktop.theme.colors.shadow}
|
||||
shadow_color ${config.alyraffauf.theme.colors.shadow}
|
||||
|
||||
default_dim_inactive 0.05
|
||||
|
||||
|
|
|
@ -1,242 +0,0 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.desktop.theme = {
|
||||
enable =
|
||||
lib.mkEnableOption "GTK and Qt themes.";
|
||||
gtk = {
|
||||
name = lib.mkOption {
|
||||
description = "GTK theme name.";
|
||||
default = "Catppuccin-Frappe-Compact-Mauve-Dark";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "GTK theme package.";
|
||||
default = pkgs.catppuccin-gtk;
|
||||
type = lib.types.package;
|
||||
};
|
||||
hideTitleBar = lib.mkOption {
|
||||
description = "Whether to hide GTK3/4 titlebars (useful for some window managers).";
|
||||
default = false;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
};
|
||||
qt = {
|
||||
name = lib.mkOption {
|
||||
description = "Qt Kvantum theme name.";
|
||||
default = "Catppuccin-Frappe-Mauve";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Qt Kvantum theme package.";
|
||||
default = pkgs.catppuccin-kvantum;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
iconTheme = {
|
||||
name = lib.mkOption {
|
||||
description = "Icon theme name.";
|
||||
default = "Papirus-Dark";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Icon theme package.";
|
||||
default = pkgs.catppuccin-papirus-folders;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
cursorTheme = {
|
||||
name = lib.mkOption {
|
||||
description = "Cursor theme name.";
|
||||
default = "Catppuccin-Frappe-Dark-Cursors";
|
||||
type = lib.types.str;
|
||||
};
|
||||
size = lib.mkOption {
|
||||
description = "Cursor size.";
|
||||
default = 24;
|
||||
type = lib.types.int;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Cursor theme package.";
|
||||
default = pkgs.catppuccin-cursors.frappeDark;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
font = {
|
||||
name = lib.mkOption {
|
||||
description = "Font name.";
|
||||
default = "NotoSans Nerd Font";
|
||||
type = lib.types.str;
|
||||
};
|
||||
size = lib.mkOption {
|
||||
description = "Font size.";
|
||||
default = 11;
|
||||
type = lib.types.int;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Font package.";
|
||||
default = pkgs.nerdfonts;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
terminalFont = {
|
||||
name = lib.mkOption {
|
||||
description = "Font name.";
|
||||
default = "NotoSansM Nerd Font";
|
||||
type = lib.types.str;
|
||||
};
|
||||
size = lib.mkOption {
|
||||
description = "Font size.";
|
||||
default = 11;
|
||||
type = lib.types.int;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Font package.";
|
||||
default = pkgs.nerdfonts;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
colors = {
|
||||
preferDark = lib.mkOption {
|
||||
description = "Whether to prefer dark mode apps or not.";
|
||||
default = config.alyraffauf.desktop.theme.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
text = lib.mkOption {
|
||||
description = "Text color.";
|
||||
default = "#FAFAFA";
|
||||
type = lib.types.str;
|
||||
};
|
||||
background = lib.mkOption {
|
||||
description = "Background color.";
|
||||
default = "#232634";
|
||||
type = lib.types.str;
|
||||
};
|
||||
primary = lib.mkOption {
|
||||
description = "Primary color.";
|
||||
default = "#CA9EE6";
|
||||
type = lib.types.str;
|
||||
};
|
||||
secondary = lib.mkOption {
|
||||
description = "Secondary color.";
|
||||
default = "#99D1DB";
|
||||
type = lib.types.str;
|
||||
};
|
||||
inactive = lib.mkOption {
|
||||
description = "Inactive color.";
|
||||
default = "#626880";
|
||||
type = lib.types.str;
|
||||
};
|
||||
shadow = lib.mkOption {
|
||||
description = "Drop shadow color.";
|
||||
default = "#1A1A1A";
|
||||
type = lib.types.str;
|
||||
};
|
||||
};
|
||||
wallpaper = lib.mkOption {
|
||||
description = "Default wallpaper.";
|
||||
default = "${config.xdg.dataHome}/backgrounds/jr-korpa-9XngoIpxcEo-unsplash.jpg";
|
||||
type = lib.types.str;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.desktop.theme.enable {
|
||||
home.pointerCursor = {
|
||||
gtk.enable = true;
|
||||
x11 = {
|
||||
enable = true;
|
||||
defaultCursor = config.alyraffauf.desktop.theme.cursorTheme.name;
|
||||
};
|
||||
name = config.alyraffauf.desktop.theme.cursorTheme.name;
|
||||
package = config.alyraffauf.desktop.theme.cursorTheme.package;
|
||||
size = config.alyraffauf.desktop.theme.cursorTheme.size;
|
||||
};
|
||||
|
||||
qt = {
|
||||
enable = true;
|
||||
platformTheme.name = "qtct";
|
||||
style.name = "kvantum";
|
||||
};
|
||||
|
||||
xdg.configFile = {
|
||||
"Kvantum/${config.alyraffauf.desktop.theme.qt.name}".source = "${config.alyraffauf.desktop.theme.qt.package}/share/Kvantum/${config.alyraffauf.desktop.theme.qt.name}";
|
||||
"Kvantum/kvantum.kvconfig".source = (pkgs.formats.ini {}).generate "kvantum.kvconfig" {
|
||||
General.theme = config.alyraffauf.desktop.theme.qt.name;
|
||||
};
|
||||
};
|
||||
|
||||
fonts.fontconfig = {
|
||||
enable = true;
|
||||
defaultFonts = {
|
||||
monospace = [config.alyraffauf.desktop.theme.terminalFont.name];
|
||||
serif = ["NotoSerif Nerd Font"];
|
||||
sansSerif = [config.alyraffauf.desktop.theme.font.name];
|
||||
};
|
||||
};
|
||||
|
||||
gtk = {
|
||||
enable = true;
|
||||
|
||||
theme = {
|
||||
package = config.alyraffauf.desktop.theme.gtk.package;
|
||||
name = config.alyraffauf.desktop.theme.gtk.name;
|
||||
};
|
||||
|
||||
iconTheme = {
|
||||
package = config.alyraffauf.desktop.theme.iconTheme.package;
|
||||
name = config.alyraffauf.desktop.theme.iconTheme.name;
|
||||
};
|
||||
|
||||
font = {
|
||||
name = "${config.alyraffauf.desktop.theme.font.name} Regular";
|
||||
package = config.alyraffauf.desktop.theme.font.package;
|
||||
size = config.alyraffauf.desktop.theme.font.size;
|
||||
};
|
||||
|
||||
gtk3.extraConfig = lib.attrsets.optionalAttrs (config.alyraffauf.desktop.theme.colors.preferDark) {gtk-application-prefer-dark-theme = 1;};
|
||||
|
||||
gtk4.extraConfig = lib.attrsets.optionalAttrs (config.alyraffauf.desktop.theme.colors.preferDark) {gtk-application-prefer-dark-theme = 1;};
|
||||
|
||||
gtk3.extraCss =
|
||||
if config.alyraffauf.desktop.theme.gtk.hideTitleBar
|
||||
then ''
|
||||
/* No (default) title bar on wayland */
|
||||
headerbar.default-decoration {
|
||||
/* You may need to tweak these values depending on your GTK theme */
|
||||
margin-bottom: 50px;
|
||||
margin-top: -100px;
|
||||
|
||||
background: transparent;
|
||||
padding: 0;
|
||||
border: 0;
|
||||
min-height: 0;
|
||||
font-size: 0;
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
/* rm -rf window shadows */
|
||||
window.csd, /* gtk4? */
|
||||
window.csd decoration { /* gtk3 */
|
||||
box-shadow: none;
|
||||
}
|
||||
''
|
||||
else "/* */";
|
||||
|
||||
gtk4.extraCss = config.gtk.gtk3.extraCss;
|
||||
};
|
||||
|
||||
dconf.settings = {
|
||||
"org/gnome/desktop/interface" = {
|
||||
gtk-theme = config.alyraffauf.desktop.theme.gtk.name;
|
||||
color-scheme = "prefer-dark";
|
||||
cursor-theme = config.alyraffauf.desktop.theme.cursorTheme.name;
|
||||
cursor-size = config.alyraffauf.desktop.theme.cursorTheme.size;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -4,11 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.desktop.waylandComp =
|
||||
lib.mkEnableOption "Shared configuration for wayland compositors.";
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.desktop.waylandComp {
|
||||
home.packages = with pkgs; [
|
||||
swayosd
|
||||
|
@ -23,11 +18,9 @@
|
|||
waybar.enable = lib.mkDefault true;
|
||||
wlogout.enable = lib.mkDefault true;
|
||||
};
|
||||
desktop = {
|
||||
theme.enable = lib.mkDefault true;
|
||||
defaultApps.enable = lib.mkDefault true;
|
||||
};
|
||||
};
|
||||
|
||||
dconf = {
|
||||
enable = true;
|
||||
|
|
386
homeManagerModules/options.nix
Normal file
386
homeManagerModules/options.nix
Normal file
|
@ -0,0 +1,386 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf = {
|
||||
apps = {
|
||||
alacritty.enable = lib.mkEnableOption "Alacritty terminal.";
|
||||
bash.enable = lib.mkEnableOption "Bash defaults.";
|
||||
chromium = {
|
||||
enable = lib.mkEnableOption "Chromium-based browser with default extensions.";
|
||||
package = lib.mkOption {
|
||||
description = "Package for Chromium.";
|
||||
default = pkgs.brave;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
emacs.enable = lib.mkEnableOption "Emacs text editor.";
|
||||
eza.enable = lib.mkEnableOption "Eza ls alternative.";
|
||||
fastfetch.enable = lib.mkEnableOption "Fastfetch.";
|
||||
firefox.enable = lib.mkEnableOption "Firefox web browser.";
|
||||
fuzzel.enable = lib.mkEnableOption "Fuzzel app launcher.";
|
||||
fzf.enable = lib.mkEnableOption "Fzf fuzzy file finder.";
|
||||
librewolf.enable = lib.mkEnableOption "Librewolf web browser.";
|
||||
mako.enable = lib.mkEnableOption "Mako notification daemon.";
|
||||
neofetch.enable = lib.mkEnableOption "Neofetch.";
|
||||
neovim.enable = lib.mkEnableOption "Neovim text editor.";
|
||||
swaylock.enable = lib.mkEnableOption "Swaylock screen locker.";
|
||||
thunar.enable = lib.mkEnableOption "Thunar file manager.";
|
||||
tmux.enable = lib.mkEnableOption "Tmux shell session manager.";
|
||||
vsCodium.enable = lib.mkEnableOption "VSCodium text editor.";
|
||||
waybar.enable = lib.mkEnableOption "Waybar wayland panel.";
|
||||
wlogout.enable = lib.mkEnableOption "Wlogout session prompt.";
|
||||
};
|
||||
defaultApps = {
|
||||
enable =
|
||||
lib.mkEnableOption "GTK and Qt themes.";
|
||||
webBrowser = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default web browser executable name.";
|
||||
default = lib.getExe config.alyraffauf.defaultApps.webBrowser.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default web browser desktop file name.";
|
||||
default = "firefox.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default web browser package.";
|
||||
default = config.programs.firefox.package;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
editor = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default editor executable name.";
|
||||
default = lib.getExe config.alyraffauf.defaultApps.editor.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default editor desktop file name.";
|
||||
default = "codium.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default editor package.";
|
||||
default = config.programs.vscode.package;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
terminalEditor = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default terminal editor executable name.";
|
||||
default = lib.getExe config.alyraffauf.defaultApps.terminalEditor.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default terminal editor desktop file name.";
|
||||
default = "nvim.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default terminal editor package.";
|
||||
default = config.programs.neovim.package;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
terminal = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default terminal executable name.";
|
||||
default = lib.getExe config.alyraffauf.defaultApps.terminal.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default terminal desktop file name.";
|
||||
default = "alacritty.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default terminal package.";
|
||||
default = config.programs.alacritty.package;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
pdfEditor = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default PDF editor executable name.";
|
||||
default = lib.getExe config.alyraffauf.defaultApps.pdfEditor.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default PDF Editor desktop file name.";
|
||||
default = "org.gnome.Evince.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default PDF Editor package.";
|
||||
default = pkgs.evince;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
imageViewer = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default image viewer executable name.";
|
||||
default = lib.getExe config.alyraffauf.defaultApps.imageViewer.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default image viewer desktop file name.";
|
||||
default = "org.gnome.eog.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default image viewer package.";
|
||||
default = pkgs.gnome.eog;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
videoPlayer = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default video player executable name.";
|
||||
default = lib.getExe config.alyraffauf.defaultApps.videoPlayer.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default video player desktop file name.";
|
||||
default = "io.github.celluloid_player.Celluloid.desktop";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default video player package.";
|
||||
default = pkgs.celluloid;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
audioPlayer = {
|
||||
exe = lib.mkOption {
|
||||
description = "Default audio player executable name.";
|
||||
default = lib.getExe config.alyraffauf.defaultApps.audioPlayer.package;
|
||||
type = lib.types.str;
|
||||
};
|
||||
desktop = lib.mkOption {
|
||||
description = "Default audio player desktop file name.";
|
||||
default = config.alyraffauf.defaultApps.videoPlayer.desktop;
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Default audio player package.";
|
||||
default = config.alyraffauf.defaultApps.videoPlayer.package;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
};
|
||||
desktop = {
|
||||
cinnamon.enable =
|
||||
lib.mkEnableOption "Cinnamon with sane defaults.";
|
||||
gnome.enable =
|
||||
lib.mkEnableOption "GNOME with sane defaults.";
|
||||
hyprland = {
|
||||
enable =
|
||||
lib.mkEnableOption "Hyprland with full desktop session components.";
|
||||
autoSuspend = lib.mkOption {
|
||||
description = "Whether to autosuspend on idle.";
|
||||
default = config.alyraffauf.desktop.hyprland.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
randomWallpaper = lib.mkOption {
|
||||
description = "Whether to enable random wallpaper script.";
|
||||
default = config.alyraffauf.desktop.hyprland.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
redShift = lib.mkOption {
|
||||
description = "Whether to redshift display colors at night.";
|
||||
default = config.alyraffauf.desktop.hyprland.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
tabletMode = {
|
||||
enable = lib.mkEnableOption "Tablet mode for hyprland.";
|
||||
autoRotate = lib.mkOption {
|
||||
description = "Whether to autorotate screen.";
|
||||
default = config.alyraffauf.desktop.hyprland.tabletMode.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
menuButton = lib.mkOption {
|
||||
description = "Whether to add menu button for waybar.";
|
||||
default = config.alyraffauf.desktop.hyprland.tabletMode.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
virtKeyboard = lib.mkOption {
|
||||
description = "Whether to enable dynamic virtual keyboard.";
|
||||
default = config.alyraffauf.desktop.hyprland.tabletMode.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
waylandComp =
|
||||
lib.mkEnableOption "Shared configuration for wayland compositors.";
|
||||
};
|
||||
scripts = {
|
||||
pp-adjuster.enable = lib.mkEnableOption "pp-adjuster script.";
|
||||
};
|
||||
services = {
|
||||
mpd = {
|
||||
enable =
|
||||
lib.mkEnableOption "MPD user service.";
|
||||
musicDirectory = lib.mkOption {
|
||||
description = "Name of music directory";
|
||||
default = config.xdg.userDirs.music;
|
||||
type = lib.types.str;
|
||||
};
|
||||
};
|
||||
easyeffects = {
|
||||
enable =
|
||||
lib.mkEnableOption "EasyEffects user service.";
|
||||
preset = lib.mkOption {
|
||||
description = "Name of preset to start with.";
|
||||
default = "";
|
||||
type = lib.types.str;
|
||||
};
|
||||
};
|
||||
};
|
||||
theme = {
|
||||
enable =
|
||||
lib.mkEnableOption "GTK and Qt themes.";
|
||||
gtk = {
|
||||
name = lib.mkOption {
|
||||
description = "GTK theme name.";
|
||||
default = "Catppuccin-Frappe-Compact-Mauve-Dark";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "GTK theme package.";
|
||||
default = pkgs.catppuccin-gtk;
|
||||
type = lib.types.package;
|
||||
};
|
||||
hideTitleBar = lib.mkOption {
|
||||
description = "Whether to hide GTK3/4 titlebars (useful for some window managers).";
|
||||
default = false;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
};
|
||||
qt = {
|
||||
name = lib.mkOption {
|
||||
description = "Qt Kvantum theme name.";
|
||||
default = "Catppuccin-Frappe-Mauve";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Qt Kvantum theme package.";
|
||||
default = pkgs.catppuccin-kvantum;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
iconTheme = {
|
||||
name = lib.mkOption {
|
||||
description = "Icon theme name.";
|
||||
default = "Papirus-Dark";
|
||||
type = lib.types.str;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Icon theme package.";
|
||||
default = pkgs.catppuccin-papirus-folders;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
cursorTheme = {
|
||||
name = lib.mkOption {
|
||||
description = "Cursor theme name.";
|
||||
default = "Catppuccin-Frappe-Dark-Cursors";
|
||||
type = lib.types.str;
|
||||
};
|
||||
size = lib.mkOption {
|
||||
description = "Cursor size.";
|
||||
default = 24;
|
||||
type = lib.types.int;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Cursor theme package.";
|
||||
default = pkgs.catppuccin-cursors.frappeDark;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
font = {
|
||||
name = lib.mkOption {
|
||||
description = "Font name.";
|
||||
default = "NotoSans Nerd Font";
|
||||
type = lib.types.str;
|
||||
};
|
||||
size = lib.mkOption {
|
||||
description = "Font size.";
|
||||
default = 11;
|
||||
type = lib.types.int;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Font package.";
|
||||
default = pkgs.nerdfonts;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
terminalFont = {
|
||||
name = lib.mkOption {
|
||||
description = "Font name.";
|
||||
default = "NotoSansM Nerd Font";
|
||||
type = lib.types.str;
|
||||
};
|
||||
size = lib.mkOption {
|
||||
description = "Font size.";
|
||||
default = 11;
|
||||
type = lib.types.int;
|
||||
};
|
||||
package = lib.mkOption {
|
||||
description = "Font package.";
|
||||
default = pkgs.nerdfonts;
|
||||
type = lib.types.package;
|
||||
};
|
||||
};
|
||||
colors = {
|
||||
preferDark = lib.mkOption {
|
||||
description = "Whether to prefer dark mode apps or not.";
|
||||
default = config.alyraffauf.theme.enable;
|
||||
type = lib.types.bool;
|
||||
};
|
||||
text = lib.mkOption {
|
||||
description = "Text color.";
|
||||
default = "#FAFAFA";
|
||||
type = lib.types.str;
|
||||
};
|
||||
background = lib.mkOption {
|
||||
description = "Background color.";
|
||||
default = "#232634";
|
||||
type = lib.types.str;
|
||||
};
|
||||
primary = lib.mkOption {
|
||||
description = "Primary color.";
|
||||
default = "#CA9EE6";
|
||||
type = lib.types.str;
|
||||
};
|
||||
secondary = lib.mkOption {
|
||||
description = "Secondary color.";
|
||||
default = "#99D1DB";
|
||||
type = lib.types.str;
|
||||
};
|
||||
inactive = lib.mkOption {
|
||||
description = "Inactive color.";
|
||||
default = "#626880";
|
||||
type = lib.types.str;
|
||||
};
|
||||
shadow = lib.mkOption {
|
||||
description = "Drop shadow color.";
|
||||
default = "#1A1A1A";
|
||||
type = lib.types.str;
|
||||
};
|
||||
};
|
||||
wallpaper = lib.mkOption {
|
||||
description = "Default wallpaper.";
|
||||
default = "${config.xdg.dataHome}/backgrounds/jr-korpa-9XngoIpxcEo-unsplash.jpg";
|
||||
type = lib.types.str;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -19,8 +19,6 @@
|
|||
${lib.getExe pkgs.libnotify} "Power profile set to $new_profile."
|
||||
'';
|
||||
in {
|
||||
options = {alyraffauf.scripts.pp-adjuster.enable = lib.mkEnableOption "Enable pp-adjuster script.";};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.scripts.pp-adjuster.enable {
|
||||
home.packages = [pp-adjuster];
|
||||
};
|
||||
|
|
|
@ -4,22 +4,14 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.services.easyeffects.enable =
|
||||
lib.mkEnableOption "EasyEffects user service.";
|
||||
alyraffauf.services.easyeffects.preset = lib.mkOption {
|
||||
description = "Name of preset to start with.";
|
||||
default = "";
|
||||
type = lib.types.str;
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.services.easyeffects.enable {
|
||||
xdg.configFile."easyeffects/output/framework13.json".source =
|
||||
xdg.configFile = {
|
||||
"easyeffects/output/framework13.json".source =
|
||||
./framework13.json;
|
||||
|
||||
xdg.configFile."easyeffects/output/LoudnessEqualizer.json".source =
|
||||
"easyeffects/output/LoudnessEqualizer.json".source =
|
||||
./LoudnessEqualizer.json;
|
||||
};
|
||||
|
||||
services.easyeffects = {
|
||||
enable = true;
|
||||
|
|
|
@ -4,16 +4,6 @@
|
|||
config,
|
||||
...
|
||||
}: {
|
||||
options = {
|
||||
alyraffauf.services.mpd.enable =
|
||||
lib.mkEnableOption "MPD user service.";
|
||||
alyraffauf.services.mpd.musicDirectory = lib.mkOption {
|
||||
description = "Name of music directory";
|
||||
default = config.xdg.userDirs.music;
|
||||
type = lib.types.str;
|
||||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf config.alyraffauf.services.mpd.enable {
|
||||
services.mpd = {
|
||||
enable = true;
|
||||
|
|
101
homeManagerModules/theme.nix
Normal file
101
homeManagerModules/theme.nix
Normal file
|
@ -0,0 +1,101 @@
|
|||
{
|
||||
pkgs,
|
||||
lib,
|
||||
config,
|
||||
...
|
||||
}: {
|
||||
config = lib.mkIf config.alyraffauf.theme.enable {
|
||||
home.pointerCursor = {
|
||||
gtk.enable = true;
|
||||
x11 = {
|
||||
enable = true;
|
||||
defaultCursor = config.alyraffauf.theme.cursorTheme.name;
|
||||
};
|
||||
name = config.alyraffauf.theme.cursorTheme.name;
|
||||
package = config.alyraffauf.theme.cursorTheme.package;
|
||||
size = config.alyraffauf.theme.cursorTheme.size;
|
||||
};
|
||||
|
||||
qt = {
|
||||
enable = true;
|
||||
platformTheme.name = "qtct";
|
||||
style.name = "kvantum";
|
||||
};
|
||||
|
||||
xdg.configFile = {
|
||||
"Kvantum/${config.alyraffauf.theme.qt.name}".source = "${config.alyraffauf.theme.qt.package}/share/Kvantum/${config.alyraffauf.theme.qt.name}";
|
||||
"Kvantum/kvantum.kvconfig".source = (pkgs.formats.ini {}).generate "kvantum.kvconfig" {
|
||||
General.theme = config.alyraffauf.theme.qt.name;
|
||||
};
|
||||
};
|
||||
|
||||
fonts.fontconfig = {
|
||||
enable = true;
|
||||
defaultFonts = {
|
||||
monospace = [config.alyraffauf.theme.terminalFont.name];
|
||||
serif = ["NotoSerif Nerd Font"];
|
||||
sansSerif = [config.alyraffauf.theme.font.name];
|
||||
};
|
||||
};
|
||||
|
||||
gtk = {
|
||||
enable = true;
|
||||
|
||||
theme = {
|
||||
package = config.alyraffauf.theme.gtk.package;
|
||||
name = config.alyraffauf.theme.gtk.name;
|
||||
};
|
||||
|
||||
iconTheme = {
|
||||
package = config.alyraffauf.theme.iconTheme.package;
|
||||
name = config.alyraffauf.theme.iconTheme.name;
|
||||
};
|
||||
|
||||
font = {
|
||||
name = "${config.alyraffauf.theme.font.name} Regular";
|
||||
package = config.alyraffauf.theme.font.package;
|
||||
size = config.alyraffauf.theme.font.size;
|
||||
};
|
||||
|
||||
gtk3.extraConfig = lib.attrsets.optionalAttrs (config.alyraffauf.theme.colors.preferDark) {gtk-application-prefer-dark-theme = 1;};
|
||||
|
||||
gtk4.extraConfig = lib.attrsets.optionalAttrs (config.alyraffauf.theme.colors.preferDark) {gtk-application-prefer-dark-theme = 1;};
|
||||
|
||||
gtk3.extraCss =
|
||||
if config.alyraffauf.theme.gtk.hideTitleBar
|
||||
then ''
|
||||
/* No (default) title bar on wayland */
|
||||
headerbar.default-decoration {
|
||||
/* You may need to tweak these values depending on your GTK theme */
|
||||
margin-bottom: 50px;
|
||||
margin-top: -100px;
|
||||
|
||||
background: transparent;
|
||||
padding: 0;
|
||||
border: 0;
|
||||
min-height: 0;
|
||||
font-size: 0;
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
/* rm -rf window shadows */
|
||||
window.csd, /* gtk4? */
|
||||
window.csd decoration { /* gtk3 */
|
||||
box-shadow: none;
|
||||
}
|
||||
''
|
||||
else "/* */";
|
||||
|
||||
gtk4.extraCss = config.gtk.gtk3.extraCss;
|
||||
};
|
||||
|
||||
dconf.settings = {
|
||||
"org/gnome/desktop/interface" = {
|
||||
gtk-theme = config.alyraffauf.theme.gtk.name;
|
||||
color-scheme = "prefer-dark";
|
||||
cursor-theme = config.alyraffauf.theme.cursorTheme.name;
|
||||
cursor-size = config.alyraffauf.theme.cursorTheme.size;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -56,12 +56,12 @@
|
|||
|
||||
hyprland.extraConfig = ''
|
||||
# Workspace - Browser
|
||||
workspace = 1, defaultName:web, on-created-empty:${config.alyraffauf.desktop.defaultApps.webBrowser.exe}
|
||||
workspace = 1, defaultName:web, on-created-empty:${config.alyraffauf.defaultApps.webBrowser.exe}
|
||||
windowrulev2 = workspace 1,class:(firefox)
|
||||
windowrulev2 = workspace 1,class:(brave-browser)
|
||||
|
||||
# Workspace - Coding
|
||||
workspace = 2, defaultName:code, on-created-empty:${config.alyraffauf.desktop.defaultApps.editor.exe}
|
||||
workspace = 2, defaultName:code, on-created-empty:${config.alyraffauf.defaultApps.editor.exe}
|
||||
windowrulev2 = workspace 2,class:(codium-url-handler)
|
||||
|
||||
# Workspace - Chrome
|
||||
|
@ -89,7 +89,23 @@
|
|||
};
|
||||
|
||||
alyraffauf = {
|
||||
desktop = {
|
||||
apps = {
|
||||
alacritty.enable = true;
|
||||
bash.enable = true;
|
||||
chromium = {
|
||||
enable = true;
|
||||
package = pkgs.brave;
|
||||
};
|
||||
emacs.enable = true;
|
||||
eza.enable = true;
|
||||
fastfetch.enable = true;
|
||||
firefox.enable = true;
|
||||
fzf.enable = true;
|
||||
neofetch.enable = true;
|
||||
neovim.enable = true;
|
||||
tmux.enable = true;
|
||||
vsCodium.enable = true;
|
||||
};
|
||||
defaultApps = {
|
||||
enable = true;
|
||||
webBrowser = {
|
||||
|
@ -97,10 +113,16 @@
|
|||
desktop = "brave-browser.desktop";
|
||||
};
|
||||
};
|
||||
desktop = {
|
||||
hyprland = {
|
||||
enable = true;
|
||||
randomWallpaper = true;
|
||||
};
|
||||
};
|
||||
|
||||
scripts = {
|
||||
pp-adjuster.enable = true;
|
||||
};
|
||||
theme = {
|
||||
enable = true;
|
||||
gtk = {
|
||||
|
@ -152,25 +174,4 @@
|
|||
wallpaper = "${config.xdg.dataHome}/backgrounds/jr-korpa-9XngoIpxcEo-unsplash.jpg";
|
||||
};
|
||||
};
|
||||
apps = {
|
||||
alacritty.enable = true;
|
||||
bash.enable = true;
|
||||
chromium = {
|
||||
enable = true;
|
||||
package = pkgs.brave;
|
||||
};
|
||||
emacs.enable = true;
|
||||
eza.enable = true;
|
||||
fastfetch.enable = true;
|
||||
firefox.enable = true;
|
||||
fzf.enable = true;
|
||||
neofetch.enable = true;
|
||||
neovim.enable = true;
|
||||
tmux.enable = true;
|
||||
vsCodium.enable = true;
|
||||
};
|
||||
scripts = {
|
||||
pp-adjuster.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -25,8 +25,17 @@
|
|||
programs.home-manager.enable = true;
|
||||
|
||||
alyraffauf = {
|
||||
desktop = {
|
||||
apps = {
|
||||
alacritty.enable = true;
|
||||
bash.enable = true;
|
||||
chromium.enable = true;
|
||||
eza.enable = true;
|
||||
firefox.enable = true;
|
||||
fzf.enable = true;
|
||||
vsCodium.enable = true;
|
||||
};
|
||||
defaultApps.enable = true;
|
||||
desktop = {
|
||||
hyprland = {
|
||||
enable = true;
|
||||
randomWallpaper = false;
|
||||
|
@ -35,6 +44,7 @@
|
|||
enable = true;
|
||||
randomWallpaper = false;
|
||||
};
|
||||
};
|
||||
theme = {
|
||||
enable = true;
|
||||
gtk = {
|
||||
|
@ -86,15 +96,4 @@
|
|||
wallpaper = "${config.xdg.dataHome}/backgrounds/jr-korpa-9XngoIpxcEo-unsplash.jpg";
|
||||
};
|
||||
};
|
||||
|
||||
apps = {
|
||||
alacritty.enable = true;
|
||||
bash.enable = true;
|
||||
chromium.enable = true;
|
||||
eza.enable = true;
|
||||
firefox.enable = true;
|
||||
fzf.enable = true;
|
||||
vsCodium.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -12,9 +12,12 @@
|
|||
"editor.fontSize" = "16";
|
||||
};
|
||||
xdg.userDirs.music = "/mnt/Media/Music";
|
||||
alyraffauf.desktop.hyprland.autoSuspend = false;
|
||||
alyraffauf.desktop.sway.autoSuspend = false;
|
||||
alyraffauf.desktop.theme = lib.mkForce {
|
||||
alyraffauf = {
|
||||
desktop = {
|
||||
hyprland.autoSuspend = false;
|
||||
sway.autoSuspend = false;
|
||||
};
|
||||
theme = lib.mkForce {
|
||||
enable = true;
|
||||
gtk = {
|
||||
name = "Catppuccin-Latte-Compact-Mauve-Light";
|
||||
|
@ -64,6 +67,7 @@
|
|||
shadow = "#1A1A1A";
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
];
|
||||
users.aly = {
|
||||
|
|
|
@ -11,11 +11,12 @@
|
|||
programs.vscode.userSettings = {
|
||||
"editor.fontSize" = "16";
|
||||
};
|
||||
alyraffauf.services.easyeffects = {
|
||||
alyraffauf = {
|
||||
services.easyeffects = {
|
||||
enable = true;
|
||||
preset = "LoudnessEqualizer";
|
||||
};
|
||||
alyraffauf.desktop.theme = {
|
||||
theme = {
|
||||
cursorTheme = lib.mkForce {
|
||||
name = "Catppuccin-Latte-Dark-Cursors";
|
||||
size = 32;
|
||||
|
@ -32,6 +33,7 @@
|
|||
package = pkgs.nerdfonts.override {fonts = ["Noto"];};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
];
|
||||
users.aly = import ../../homes/aly.nix;
|
||||
|
|
Loading…
Reference in a new issue