# SPDX-FileCopyrightText: 2022 Simon Bruder # # SPDX-License-Identifier: AGPL-3.0-or-later { lib, nixosConfig, pkgs, ... }: lib.mkIf nixosConfig.programs.corectrl.enable { systemd.user.services.corectrl = { Unit = { Requires = [ "tray.target" ]; After = [ "graphical-session-pre.target" "tray.target" ]; PartOf = [ "graphical-session.target" ]; }; Install = { WantedBy = [ "graphical-session.target" ]; }; Service = { ExecStart = "${pkgs.corectrl}/bin/corectrl"; }; }; xdg.configFile."corectrl/corectrl.ini".text = lib.generators.toINI { } { General = { startOnSysTray = "true"; }; }; }