2024-06-12 09:54:11 +07:00
|
|
|
{ lib, pkgs, unstable, config, ... }:
|
|
|
|
let
|
|
|
|
cfg = config.profile.hyprland;
|
|
|
|
draw-wallpaper = rec {
|
|
|
|
filename = "select-wallpaper.sh";
|
|
|
|
script = pkgs.writeScriptBin filename (builtins.readFile ./scripts/draw-wallpaper.sh);
|
|
|
|
path = "${script}/bin/${filename}";
|
|
|
|
};
|
|
|
|
in
|
|
|
|
{
|
|
|
|
config = lib.mkIf cfg.enable {
|
|
|
|
home.packages = [ unstable.pyprland unstable.swww ];
|
|
|
|
home.file.".config/hypr/pyprland.toml".source =
|
|
|
|
let
|
|
|
|
tomlFormat = pkgs.formats.toml { };
|
|
|
|
in
|
|
|
|
tomlFormat.generate "pyprland.toml" {
|
|
|
|
# https://github.com/hyprland-community/pyprland/wiki/Getting-started#configuring
|
|
|
|
pyprland.plugins = [
|
2024-08-01 22:22:01 +07:00
|
|
|
# "scratchpads"
|
|
|
|
# "fetch_client_menu"
|
2024-06-12 09:54:11 +07:00
|
|
|
"wallpapers"
|
|
|
|
];
|
2024-08-01 22:22:01 +07:00
|
|
|
# scratchpads.term = {
|
|
|
|
# animation = "fromTop";
|
|
|
|
# command = "foot --app-id foot-scratchpad";
|
|
|
|
# class = "foot-scratchpad";
|
|
|
|
# size = "75% 75%";
|
|
|
|
# };
|
2024-06-12 09:54:11 +07:00
|
|
|
wallpapers = {
|
|
|
|
path = cfg.pyprland.wallpaper-dirs;
|
|
|
|
unique = false;
|
|
|
|
command = ''${draw-wallpaper.path} [file]'';
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|