New services and package updates

- Added support for open-webui and ollama-rocm in CLI packages.
- Updated desktop packages to include filezilla, audacity, and freecad.
- Expanded essentials with distrobox, dbus, cifs-utils, samba, and kdePackages.ksshaskpass.
- Introduced niri-waybar and niri-session-manager services for improved session management.
- Configured mako notifications with custom settings in the Niri environment.
- Adjusted hyprpaper settings and enabled additional wallpapers. (TODO on niri. Not working ATM)
This commit is contained in:
2026-02-04 11:20:05 +01:00
parent feb65868cc
commit 7a0ea8c4f1
8 changed files with 113 additions and 15 deletions

51
niri/autostart.nix Normal file
View File

@ -0,0 +1,51 @@
{ config, pkgs, username, project, ... }:
{
#To show logs of services run:
#journalctl --user-unit={service-name} --user
systemd.user.services.niri-waybar = {
description = "Waybar status bar for Niri";
# "wantedBy" replaces the [Install] section
wantedBy = [ "graphical-session.target" ];
# "partOf" and "after" replace the [Unit] section dependencies
partOf = [ "graphical-session.target" ];
after = [ "graphical-session.target" ];
# [Unit] configuration goes here
unitConfig = {
# This checks the environment variable to ensure we are in Niri
ConditionEnvironment = "XDG_CURRENT_DESKTOP=niri";
};
# [Service] configuration goes here
serviceConfig = {
ExecStart = "${pkgs.waybar}/bin/waybar";
Restart = "on-failure";
RestartSec = "1s";
};
};
# 2. The Niri Session Cleanup Service
# This service starts when the graphical session starts, and when it stops,
# it forcibly stops the graphical-session.target to ensure a clean state for the next login.
systemd.user.services.niri-session-manager = {
description = "Niri Session Management";
wantedBy = [ "graphical-session.target" ];
partOf = [ "graphical-session.target" ];
# Only run this cleanup logic for Niri
unitConfig.ConditionEnvironment = "XDG_CURRENT_DESKTOP=niri";
serviceConfig = {
Type = "simple";
# A dummy command that stays alive. 'sleep infinity' is low resource.
ExecStart = "${pkgs.coreutils}/bin/sleep infinity";
# IMPORTANT: When this service stops (which happens when niri kills its children),
# it brings down the whole target.
ExecStopPost = "${pkgs.systemd}/bin/systemctl --user stop graphical-session.target";
};
};
}

View File

@ -6,6 +6,11 @@
../modules/waybar/home.nix
];
xdg.configFile."mako/config".text = ''
default-timeout=5000
ignore-timeout=1
'';
programs.niri = {
package = pkgs.niri;
enable = true;
@ -76,8 +81,9 @@
}
}
spawn-at-startup "waybar"
// spawn-at-startup "waybar"
spawn-at-startup "hyprpaper"
spawn-at-startup "${pkgs.mako}/bin/mako"
// spawn-sh-at-startup "qs -c ~/source/qs/MyAwesomeShell"
@ -150,8 +156,8 @@
Mod+Ctrl+End { move-column-to-last; }
Mod+Shift+Left { focus-monitor-left; }
Mod+Shift+Down { focus-monitor-down; }
Mod+Shift+Up { focus-monitor-up; }
Mod+Shift+Down { move-window-down-or-to-workspace-down; }
Mod+Shift+Up { move-window-up-or-to-workspace-up; }
Mod+Shift+Right { focus-monitor-right; }
Mod+Shift+H { focus-monitor-left; }
Mod+Shift+J { focus-monitor-down; }

View File

@ -1,7 +1,7 @@
{ config, inputs, pkgs, ... }:
{
imports = [
# ./autostart.nix
./autostart.nix
../modules/hyprlock
../modules/hyprpaper
../modules/stylix
@ -13,9 +13,10 @@
environment.systemPackages = with pkgs;
[
mako
#mako
fuzzel
waybar
xwayland-satellite
];
programs = {