Use alejandra formatter / fix warnings

This commit is contained in:
DashieTM 2025-02-15 16:23:22 +01:00
parent c5b1041bbb
commit 693d4e3c70
70 changed files with 1424 additions and 1547 deletions

View file

@ -4,8 +4,7 @@
options,
pkgs,
...
}:
{
}: {
options.mods.flatpak = {
enable = lib.mkOption {
default = true;
@ -14,15 +13,15 @@
description = "Enables the flatpak package manager";
};
additional_packages = lib.mkOption {
default = [ ];
example = [ ];
default = [];
example = [];
type = with lib.types; listOf str;
description = "Flatpak packages";
};
};
config = lib.mkIf config.mods.flatpak.enable (
lib.optionalAttrs (options ? services.flatpak.remote) {
environment.systemPackages = [ pkgs.flatpak ];
environment.systemPackages = [pkgs.flatpak];
services.flatpak.remotes = lib.mkOptionDefault [
{
name = "flathub-stable";
@ -32,11 +31,13 @@
services.flatpak.uninstallUnmanaged = true;
}
// lib.optionalAttrs (options ? services.flatpak.packages) {
services.flatpak.packages = [
# fallback if necessary, but generally avoided as nix is superior :)
# default flatseal installation since flatpak permissions are totally not a broken idea
"com.github.tchx84.Flatseal"
] ++ config.mods.flatpak.additional_packages;
services.flatpak.packages =
[
# fallback if necessary, but generally avoided as nix is superior :)
# default flatseal installation since flatpak permissions are totally not a broken idea
"com.github.tchx84.Flatseal"
]
++ config.mods.flatpak.additional_packages;
}
);
}