1
0
Fork 0
mirror of https://github.com/nix-community/home-manager synced 2024-11-24 03:59:46 +01:00
home-manager/modules/services/blueman-applet.nix

43 lines
1 KiB
Nix
Raw Normal View History

2017-09-12 16:26:52 +02:00
{ config, lib, pkgs, ... }:
with lib;
{
options = {
services.blueman-applet = {
enable = mkEnableOption "" // {
description = ''
Whether to enable the Blueman applet.
Note that for the applet to work, the `blueman` service should
be enabled system-wide. You can enable it in the system
configuration using
```nix
services.blueman.enable = true;
```
'';
};
2017-09-12 16:26:52 +02:00
};
};
config = mkIf config.services.blueman-applet.enable {
2022-04-24 16:25:54 +02:00
assertions = [
(hm.assertions.assertPlatform "services.blueman-applet" pkgs
platforms.linux)
];
2017-09-12 16:26:52 +02:00
systemd.user.services.blueman-applet = {
2020-02-02 00:39:17 +01:00
Unit = {
Description = "Blueman applet";
Requires = [ "tray.target" ];
After = [ "graphical-session-pre.target" "tray.target" ];
2020-02-02 00:39:17 +01:00
PartOf = [ "graphical-session.target" ];
};
2017-09-12 16:26:52 +02:00
2020-02-02 00:39:17 +01:00
Install = { WantedBy = [ "graphical-session.target" ]; };
2017-09-12 16:26:52 +02:00
2020-02-02 00:39:17 +01:00
Service = { ExecStart = "${pkgs.blueman}/bin/blueman-applet"; };
2017-09-12 16:26:52 +02:00
};
};
}