{ config, pkgs, ... }: { services.flatpak.enable = true; /* Create systemd service that adds flathub after getting network This adds it automatically, which avoids the whack ass way I was doing that before */ systemd.services.flathub-add = { description = "Add flathub repo to system flatpak install"; script = "${pkgs.flatpak}/bin/flatpak remote-add --if-not-exists flathub https://dl.flathub.org/repo/flathub.flatpakrepo"; serviceConfig.Type = "oneshot"; wantedBy = [ "network-online.target" ]; # Run after networking is working after = [ "NetworkManager-wait-online.service" ]; }; }