feat(desktop): disable river and go back to hyprland.

This commit is contained in:
CronyAkatsuki 2025-06-07 08:35:36 +02:00
parent 5d041294a4
commit 13b96d9574
5 changed files with 92 additions and 53 deletions

View file

@ -104,10 +104,10 @@
# Enable light for image control
programs.light.enable = true;
programs.river = {
enable = true;
extraPackages = [];
};
# programs.river = {
# enable = true;
# extraPackages = [];
# };
# Define a user account. Don't forget to set a password with passwd.
users.users.crony = {
@ -139,6 +139,7 @@
crony.secrets.enable = true;
crony.ryzenadj.enable = true;
crony.auto-cpufreq.enable = true;
crony.hyprland-nixos.enable = true;
xdg.portal = {
enable = true;

View file

@ -30,7 +30,8 @@
crony.gaming.enable = true;
crony.flatpak.enable = true;
crony.wayland.enable = true;
crony.river.enable = true;
crony.river.enable = false;
crony.hyprland.enable = true;
# DO NOT CHANGE ALSO
home.stateVersion = "24.11"; # Please read the comment before changing.

View file

@ -78,6 +78,38 @@ in {
};
config = lib.mkIf config.crony.hyprland.enable {
# Enable hyprpaper
services.hyprpaper.enable = true;
# Enable hypridle
services.hypridle = {
enable = true;
settings = {
general = {
lock_cmd = "pidof hyprlock || hyprlock"; # avoid starting multiple hyprlock instances.
before_sleep_cmd = "loginctl lock-session"; # lock before suspend.
after_sleep_cmd = "hyprctl dispatch dpms on"; # to avoid having to press a key twice to turn on the display.
};
listener = [
{
timeout = 10; # 10 sec
on-timeout = "pidof hyprlock && hyprctl dispatch dpms off"; # Turn off screen if hyprlock is running
on-resume = "hyprctl dispatch dpms on"; # Turn on screen when activiy is detected after timeout has fired
}
{
timeout = 300; # 5min
on-timeout = "loginctl lock-session"; # lock screen when timeout has passed
}
{
timeout = 310; # 5min and 10 sec
on-timeout = "hyprctl dispatch dpms off"; # Turn off screen if hyprlock is running
on-resume = "hyprctl dispatch dpms on"; # Turn on screen when activiy is detected after timeout has fired
}
];
};
};
# Setup and enable hyprland
wayland.windowManager.hyprland = {
enable = true;
@ -95,10 +127,10 @@ in {
];
exec-once = [
"waybar" # Start waybar on start
"wl-paste --type text --watch cliphist store" # Stores only text data
"wl-paste --type image --watch cliphist store" # Stores only image data
"keepassxc" # Startup my password manager
"waybar" # Start waybar on start
];
monitor = [
@ -107,25 +139,25 @@ in {
];
animations = {
enabled = "yes";
enabled = false;
};
decoration = {
blur = {
enabled = true;
enabled = false;
};
shadow = {
enabled = true;
enabled = false;
};
rounding = 10;
rounding = 0;
};
general = {
border_size = 3;
gaps_in = 5;
gaps_out = 10;
border_size = 1;
gaps_in = 3;
gaps_out = 6;
layout = "master";
allow_tearing = true;
};

View file

@ -51,8 +51,28 @@ in {
playerctl
grim
libnotify
wlopm
];
services.way-displays = {
enable = true;
settings = {
SCALING = false;
DISABLED = [
{
NAME_DESC = "eDP-1";
IF = [
{
PLUGGED = [
"HDMI-A-1"
];
}
];
}
];
};
};
wayland.windowManager.river = {
enable = true;
settings = {

View file

@ -52,37 +52,16 @@
};
};
# Enable hyprpaper
services.hyprpaper.enable = true;
# Enable hypridle
services.hypridle = {
services.swayidle = {
enable = true;
settings = {
general = {
lock_cmd = "pidof hyprlock || hyprlock"; # avoid starting multiple hyprlock instances.
before_sleep_cmd = "loginctl lock-session"; # lock before suspend.
after_sleep_cmd = "hyprctl dispatch dpms on"; # to avoid having to press a key twice to turn on the display.
};
listener = [
timeouts = [
{
timeout = 10; # 10 sec
on-timeout = "pidof hyprlock && hyprctl dispatch dpms off"; # Turn off screen if hyprlock is running
on-resume = "hyprctl dispatch dpms on"; # Turn on screen when activiy is detected after timeout has fired
}
{
timeout = 300; # 5min
on-timeout = "loginctl lock-session"; # lock screen when timeout has passed
}
{
timeout = 310; # 5min and 10 sec
on-timeout = "hyprctl dispatch dpms off"; # Turn off screen if hyprlock is running
on-resume = "hyprctl dispatch dpms on"; # Turn on screen when activiy is detected after timeout has fired
timeout = 10;
command = "pidof hyprlock && ${pkgs.wlopm}/bin/wlopm --off '*'";
resumeCommand = "${pkgs.wlopm}/bin/wlopm --on '*'";
}
];
};
};
# Enable hyprlock
programs.hyprlock = {
@ -137,21 +116,25 @@
padding-left: 10px;
}
#tags {
#workspaces {
background-color: @base01;
margin: 0.25em;
border-radius: 1em;
}
#tags button {
#workspaces button {
padding: 0 0.5em;
color: @base03;
}
#tags button.occupied {
color: @base06;
}
#tags button.focused {
#workspaces button.empty {
color: @base03;
}
#workspaces button.visible {
color: @base06;
}
#workspaces button.active {
color: @base0D;
}
@ -185,8 +168,8 @@
mainBar = {
height = 34;
modules-left = [
"river/tags"
"river/window"
"hyprland/workspaces"
"hyprland/window"
];
modules-center = [
];
@ -199,8 +182,10 @@
"clock"
"tray"
];
"river/window" = {
max-length = 50;
"hyprland/workspaces" = {
persistent-workspaces = {
"*" = [1 2 3 4 5 6 7 8 9];
};
};
disk = {
path = "/";