diff --git a/packages.nix b/packages.nix index f2e4c0f..28b8996 100644 --- a/packages.nix +++ b/packages.nix @@ -11,6 +11,7 @@ in ./programs ./overlays.nix ./packages/unstable.nix + ./packages/flatpak.nix (mkRenamedOptionModule [ "aviallon" "programs" "compileFlags" ] [ "aviallon" "optimizations" "extraCompileFlags" ]) ]; diff --git a/packages/flatpak.nix b/packages/flatpak.nix new file mode 100644 index 0000000..393b53a --- /dev/null +++ b/packages/flatpak.nix @@ -0,0 +1,25 @@ +{ config, pkgs, lib, ...}: +with lib; +let + desktopCfg = config.aviallon.desktop; +in { + config = {} + // { + services.flatpak.enable = mkDefault true; + systemd.services.flatpak-add-flathub = { + script = '' + exec ${pkgs.flatpak}/bin/flatpak remote-add --if-not-exists flathub https://flathub.org/repo/flathub.flatpakrepo + ''; + requires = [ + "network-online.target" + ]; + after = [ + "network-online.target" + ]; + wantedBy = [ + "graphical.target" + ]; + }; + } + ; +}