58 lines
1.0 KiB
Nix
58 lines
1.0 KiB
Nix
{
|
|
inputs,
|
|
pkgs,
|
|
lib,
|
|
config,
|
|
...
|
|
}: let
|
|
requiredDeps = with pkgs; [
|
|
bash
|
|
bun
|
|
coreutils
|
|
dart-sass
|
|
gawk
|
|
imagemagick
|
|
procps
|
|
ripgrep
|
|
util-linux
|
|
];
|
|
|
|
guiDeps = with pkgs; [
|
|
gnome.gnome-control-center
|
|
mission-center
|
|
overskride
|
|
wlogout
|
|
];
|
|
|
|
dependencies = requiredDeps ++ guiDeps;
|
|
inherit (lib) mkIf mkEnableOption;
|
|
cfg = config.modules.utils.ags;
|
|
in {
|
|
imports = [
|
|
inputs.ags.homeManagerModules.default
|
|
];
|
|
options = {
|
|
modules.utils.ags.enable = mkEnableOption "Enables ags";
|
|
};
|
|
|
|
config = mkIf cfg.enable {
|
|
programs.ags.enable = true;
|
|
|
|
systemd.user.services.ags = {
|
|
Unit = {
|
|
Description = "Aylur's Gtk Shell";
|
|
PartOf = [
|
|
"tray.target"
|
|
"graphical-session.target"
|
|
];
|
|
};
|
|
Service = {
|
|
Environment = "PATH=/run/wrappers/bin:${lib.makeBinPath dependencies}";
|
|
ExecStart = "${cfg.package}/bin/ags";
|
|
Restart = "on-failure";
|
|
};
|
|
Install.WantedBy = ["graphical-session.target"];
|
|
};
|
|
};
|
|
}
|