Files
samfelag/modules/desktop/grapheio.nix
2025-02-16 22:51:22 +01:00

127 lines
3.7 KiB
Nix
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{ config, lib, pkgs, inputs, ... }:
with lib;
let
cfg = config.samfelag.modules.desktop.grapheio;
hyprCfg = config.samfelag.modules.desktop.wm.hyprland;
in
{
options.samfelag.modules.desktop.grapheio = {
enable = mkEnableOption "Γραφείο desktop environment - hyprland based";
};
config = mkIf cfg.enable {
# - Packages ---------------------------------
environment.systemPackages = with pkgs; [
# - Tools ----------------------------------
jq
# - Appearance -----------------------------
rose-pine-gtk-theme
rose-pine-icon-theme
# - Cursor
inputs.hyprcursor-rose-pine.packages.${pkgs.system}.default
rose-pine-cursor
];
# - Data files -------------------------------
hm.xdg.configFile."grapheio".source = ../../config/grapheio;
# - Cursor -----------------------------------
hm.home.pointerCursor = {
gtk.enable = true;
package = pkgs.rose-pine-cursor;
name = "BreezeX Cursor";
size = 24;
};
hm.gtk = {
enable = true;
theme = {
package = pkgs.rose-pine-gtk-theme;
name = "rose-pine-gtk-theme";
};
iconTheme = {
package = pkgs.rose-pine-icon-theme;
name = "rose-pine-icons";
};
cursorTheme = {
package = pkgs.rose-pine-cursor;
name = "BreezeX-RoséPine";
size = 24;
};
};
# - Hyprland keybindings ---------------------
hm.wayland.windowManager.hyprland.settings = lib.mkIf hyprCfg.enable {
bind = [
# Pulse Audio controls (mute)
", XF86AudioMute, exec, $HOME/.config/grapheio/scripts/volume.sh mute"
# Media player controls
", XF86AudioPlay, exec, playerctl play-pause"
", XF86AudioPause, exec, playerctl play-pause"
", XF86AudioNext, exec, playerctl next"
", XF86AudioPrev, exec, playerctl previous"
", XF86AudioStop, exec, playerctl stop"
# Keyboard brightness control
"${hyprCfg.mod}, XF86MonBrightnessUp, exec, brightnessctl -d platform::kbd_backlight set +1"
"${hyprCfg.mod}, XF86MonBrightnessDown, exec, brightnessctl -d platform::kbd_backlight set -1"
];
binde = [
# Pulse Audio controls (keep button pressed)
", XF86AudioRaiseVolume, exec, $HOME/.config/grapheio/scripts/volume.sh set +5%"
", XF86AudioLowerVolume, exec, $HOME/.config/grapheio/scripts/volume.sh set -5%"
# Brightness control (keep button pressed)
", XF86MonBrightnessUp, exec, $HOME/.config/grapheio/scripts/brightness.sh set +5%"
", XF86MonBrightnessDown, exec, $HOME/.config/grapheio/scripts/brightness.sh set 5%-"
# Keyboard brightness control (keep button pressed)
"${hyprCfg.mod}, XF86MonBrightnessUp, exec, $HOME/.config/grapheio/scripts/brightness.sh kb_set +1"
"${hyprCfg.mod}, XF86MonBrightnessDown, exec, $HOME/.config/grapheio/scripts/brightness.sh kb_set 1-"
];
};
# - Modules ----------------------------------
samfelag.modules = {
system.audio.enable = true;
system.brightness.enable = true;
desktop = {
# Window Manager
wm.hyprland.enable = true;
tools = {
# Greeter (login screen)
greetd = {
enable = true;
wm_cmd = "Hyprland";
};
# Locker
hyprlock.enable = true;
# Status bars
eww.enable = true;
# Wallpapper
hyprpaper.enable = true;
# Launcher
rofi.enable = true;
# Notification center
swaync.enable = true;
};
};
app = {
alacritty.enable = true;
zen-browser.enable = true;
};
};
};
}