plan9port: add module

This commit is contained in:
Emery Hemingway 2020-07-28 23:16:31 +02:00 committed by Robert Helgesson
parent f0e6396b78
commit 73506f947c
No known key found for this signature in database
GPG Key ID: 36BDAA14C2797E89
4 changed files with 47 additions and 1 deletions

2
.github/CODEOWNERS vendored
View File

@ -202,6 +202,8 @@
/modules/services/pbgopy.nix @ivarwithoutbones
/tests/modules/services/pbgopy @ivarwithoutbones
/modules/services/plan9port.nix @ehmry
/modules/services/pulseeffects.nix @jonringer
/modules/services/random-background.nix @rycee

View File

@ -1804,7 +1804,15 @@ in
https://github.com/nix-community/home-manager/issues/1691
for discussion.
'';
'';
}
{
time = "2021-01-02T07:49:15+00:00";
condition = hostPlatform.isLinux;
message = ''
A new module is available: 'services.plan9port'.
'';
}
];
};

View File

@ -173,6 +173,7 @@ let
(loadModule ./services/pasystray.nix { })
(loadModule ./services/pbgopy.nix { condition = hostPlatform.isLinux; })
(loadModule ./services/picom.nix { })
(loadModule ./services/plan9port.nix { condition = hostPlatform.isLinux; })
(loadModule ./services/polybar.nix { })
(loadModule ./services/pulseeffects.nix { condition = hostPlatform.isLinux; })
(loadModule ./services/random-background.nix { })

View File

@ -0,0 +1,35 @@
{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.services.plan9port;
in {
meta.maintainers = [ maintainers.ehmry ];
options.services.plan9port = {
fontsrv.enable =
mkEnableOption "the Plan 9 file system access to host fonts";
plumber.enable =
mkEnableOption "the Plan 9 file system for interprocess messaging";
};
config = {
systemd.user.services.fontsrv = mkIf cfg.fontsrv.enable {
Unit.Description = "the Plan 9 file system access to host fonts";
Install.WantedBy = [ "default.target" ];
Service.ExecStart = "${pkgs.plan9port}/bin/9 fontsrv";
};
systemd.user.services.plumber = mkIf cfg.plumber.enable {
Unit.Description = "file system for interprocess messaging";
Install.WantedBy = [ "default.target" ];
Service.ExecStart = "${pkgs.plan9port}/bin/9 plumber -f";
};
};
}