Working config for fw13 amd

This commit is contained in:
Jurn Wubben 2025-02-14 19:40:27 +00:00
commit b7147ec26e
49 changed files with 1812 additions and 0 deletions

View file

@ -0,0 +1,102 @@
{
config,
lib,
pkgs,
...
}: let
inherit (lib) getExe;
runOnce = program: "pgrep ${program} || uwsm app -- ${program}";
uwsm = getExe pkgs.uwsm;
hyprlock = runOnce (getExe pkgs.hyprlock);
#TODO: Move these functions into a separate lib file.
#TODO: Possibly migrate some of these applications into an option.
#TODO: Stylix
app = app: "${uwsm} app -- ${app}";
appE = appE: app (getExe appE);
termapp = termapp: "${foot} '${termapp}'";
termappE = termappE: termapp (getExe termappE);
foot = appE pkgs.foot;
fuzzel = appE config.programs.fuzzel.package;
firefox = appE pkgs.firefox;
playerctl = appE pkgs.playerctl;
brightnessctl = appE pkgs.brightnessctl;
wpctl = app "${pkgs.wireplumber}/bin/wpctl";
pulsemixer = termappE pkgs.pulsemixer;
bluetui = termappE pkgs.bluetui;
nmtui = termapp "${pkgs.networkmanager}/bin/nmtui";
# toggle = program: let
# prog = builtins.substring 0 14 program;
# in "pkill ${prog} || ${uwsm} app -- ${program}";
workspaces = builtins.concatLists (builtins.genList (
x: let
ws = let
c = (x + 1) / 10;
in
builtins.toString (x + 1 - (c * 10));
in [
"$mod, ${ws}, workspace, ${toString (x + 1)}"
"$mod SHIFT, ${ws}, movetoworkspace, ${toString (x + 1)}"
]
)
10);
in {
wayland.windowManager.hyprland.settings = {
"$mod" = "ALT";
bindm = [
"$mod, mouse:272, movewindow"
"$mod, mouse:273, resizewindow"
"$mod ALT, mouse:272, resizewindow"
];
bind =
[
"$mod SHIFT, E, exec, uwsm stop"
"$mod, Q, killactive,"
"$mod, F, fullscreen,"
"$mod, SPACE, togglefloating,"
"$mod, O, pseudo,"
"$mod ALT, ,resizeactive,"
"$mod, D, exec, ${fuzzel}"
"$mod, Return, exec, ${foot}"
"$mod Shift, Return, exec, ${firefox}"
"$mod, Escape, exec, ${hyprlock}"
"$mod, A, exec, ${pulsemixer}"
"$mod, B, exec, ${bluetui}"
"$mod, N, exec, ${nmtui}"
"$mod, h, movefocus, l"
"$mod, l, movefocus, r"
"$mod, k, movefocus, u"
"$mod, j, movefocus, d"
]
++ workspaces;
bindl = [
# media controls
", XF86AudioPlay, exec, ${playerctl} play-pause"
", XF86AudioPrev, exec, ${playerctl} previous"
", XF86AudioNext, exec, ${playerctl} next"
# volume
", XF86AudioMute, exec, ${wpctl} set-mute @DEFAULT_AUDIO_SINK@ toggle"
", XF86AudioMicMute, exec, ${wpctl} set-mute @DEFAULT_AUDIO_SOURCE@ toggle"
];
bindle = [
# volume
", XF86AudioRaiseVolume, exec, ${wpctl} set-volume -l '1.0' @DEFAULT_AUDIO_SINK@ 6%+"
", XF86AudioLowerVolume, exec, ${wpctl} set-volume -l '1.0' @DEFAULT_AUDIO_SINK@ 6%-"
",XF86MonBrightnessUp, exec, ${brightnessctl} s 10%+"
",XF86MonBrightnessDown, exec, ${brightnessctl} s 10%-"
];
};
}

View file

@ -0,0 +1,28 @@
{
lib,
pkgs,
...
}: let
inherit (lib) getExe;
uwsm = getExe pkgs.uwsm;
hyprlock = getExe pkgs.hyprlock;
in {
imports = [
./binds.nix
./settings.nix
];
wayland.windowManager.hyprland = {
enable = true;
settings = {
env = [
"QT_WAYLAND_DISABLE_WINDOWDECORATION,1"
];
exec-once = [
"${uwsm} finalize"
"${hyprlock}" # Lock screen
];
};
};
}

View file

@ -0,0 +1,88 @@
{
wayland.windowManager.hyprland.settings = {
general = {
gaps_in = 5;
gaps_out = 5;
border_size = 1;
resize_on_border = true;
};
decoration = {
rounding = 10;
rounding_power = 3;
blur = {
enabled = true;
brightness = 1.0;
contrast = 1.0;
noise = 0.01;
vibrancy = 0.2;
vibrancy_darkness = 0.5;
passes = 4;
size = 7;
popups = true;
popups_ignorealpha = 0.2;
};
shadow = {
enabled = true;
ignore_window = true;
offset = "0 15";
range = 100;
render_power = 2;
scale = 0.97;
};
};
animations = {
enabled = true;
animation = [
"border, 1, 2, default"
"fade, 1, 4, default"
"windows, 1, 3, default, popin 80%"
"workspaces, 1, 2, default, slide"
];
};
group = {
groupbar = {
font_size = 10;
gradients = false;
};
};
input = {
repeat_rate = 60;
repeat_delay = 200;
kb_layout = "us";
follow_mouse = 1;
sensitivity = 0; # -1.0 - 1.0, 0 means no modification.
kb_options = "compose:ralt";
touchpad = {
natural_scroll = false;
};
};
gestures = {
workspace_swipe = true;
workspace_swipe_forever = true;
workspace_swipe_direction_lock = false;
};
dwindle = {
pseudotile = true;
preserve_split = true;
};
misc = {
disable_autoreload = true;
force_default_wallpaper = 0;
animate_mouse_windowdragging = false;
vrr = 1;
};
};
}