Switches to uwsm for Hyprland session setup, WIP portals config needs cleanup

- Disables systemd management in favor of uwsm
- Updates environment variables for Wayland and portal support
- Adds xdg-desktop-portal packages to dependencies
- Adjusts greetd and Wayland configuration for uwsm integration
This commit is contained in:
Chris Toph 2025-04-14 13:50:59 -04:00
parent 81d5517506
commit 99cd170ffe
5 changed files with 29 additions and 15 deletions

View file

@ -11,30 +11,40 @@
wayland.windowManager.hyprland = {
enable = true;
# withUWSM = true; # One day, but not today
systemd.enable = false; # using withUWSM
package = null;
portalPackage = null;
systemd = {
enable = true;
variables = [ "--all" ];
extraCommands = lib.mkBefore [
"systemctl --user stop graphical-session.target"
"systemctl --user start hyprland-session.target"
];
};
# systemd = {
# enable = true;
# variables = [ "--all" ];
# extraCommands = lib.mkBefore [
# "systemctl --user stop graphical-session.target"
# "systemctl --user start hyprland-session.target"
# ];
# };
settings = {
## Environment Vars ##
env = [
"NIXOS_XDG_OPEN_USE_PORTAL, 1" # for xdg-open to use portal
"NIXOS_OZONE_WL, 1" # for ozone-based and electron apps to run on wayland
"MOZ_ENABLE_WAYLAND, 1" # for firefox to run on wayland
"MOZ_WEBRENDER, 1" # for firefox to run on wayland
"XDG_SESSION_TYPE,wayland"
"XDG_SESSION_DESKTOP,Hyprland"
"XDG_CURRENT_DESKTOP,Hyprland"
"WLR_NO_HARDWARE_CURSORS,1"
"WLR_RENDERER_ALLOW_SOFTWARE,1"
"QT_QPA_PLATFORM,wayland"
"GTK_USE_PORTAL,1"
"HYPRCURSOR_THEME,rose-pine-hyprcursor" # this will be better than default for now
];
xwayland = {
force_zero_scaling = true;
};
## Monitor ##
monitor = (

View file

@ -42,6 +42,9 @@
## Productivity ##
gimp
inkscape
xdg-desktop-portal-gtk
xdg-desktop-portal-hyprland
;
};

View file

@ -10,7 +10,7 @@
programs.hyprland = {
enable = true;
# withUWSM = true; # One day, but not today
withUWSM = true;
};
environment.systemPackages = [

View file

@ -13,11 +13,12 @@
let
hostSpec = config.hostSpec.username;
default = {
command = "${pkgs.greetd.tuigreet}/bin/tuigreet --asterisks --time --time-format '%I:%M %p | %a %h | %F' --cmd Hyprland";
command = "${pkgs.greetd.tuigreet}/bin/tuigreet --asterisks --time --time-format '%I:%M %p | %a %h | %F' --cmd uwsm start hyprland.desktop";
user = "toph";
};
initial = {
command = "${pkgs.hyprland}/bin/Hyprland";
# command = "${pkgs.hyprland}/bin/Hyprland";
command = "uwsm start hyprland.desktop";
user = "toph";
};
in

View file

@ -14,9 +14,9 @@
xdgOpenUsePortal = true;
extraPortals = [
pkgs.xdg-desktop-portal-gtk
pkgs.xdg-desktop-portal-hyprland
# pkgs.xdg-desktop-portal-hyprland
];
configPackages = [ pkgs.hyprland ];
config.common.default = "*";
# configPackages = [ pkgs.hyprland ];
# config.common.default = "*";
};
}