depot/third_party/home-manager/modules/services/parcellite.nix
Default email 72904c318c Project import generated by Copybara.
GitOrigin-RevId: 9bf1f40af124573a54fd208b1f539eb694ef31a6
2020-10-11 17:22:58 -07:00

35 lines
726 B
Nix

{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.services.parcellite;
package = pkgs.parcellite;
in {
meta.maintainers = [ maintainers.gleber ];
options = {
services.parcellite = { enable = mkEnableOption "Parcellite"; };
};
config = mkIf cfg.enable {
home.packages = [ package ];
systemd.user.services.parcellite = {
Unit = {
Description = "Lightweight GTK+ clipboard manager";
After = [ "graphical-session-pre.target" ];
PartOf = [ "graphical-session.target" ];
};
Install = { WantedBy = [ "graphical-session.target" ]; };
Service = {
ExecStart = "${package}/bin/parcellite";
Restart = "on-abort";
};
};
};
}