fnott: refactor module
- Change generation behavior to always generate a configuration file and pass it explicitly to fnott, it enforces the module to be hermetic instead of offloading the configuration selection to heuristics. - Various style changes. - Fix issue where fnott would abort due to an invalid config file when both the configFile and settings options are unset. - Remove the empty-settings test as a configuration file is now already generated. Suggested-by: Robert Helgesson <robert@rycee.net>
This commit is contained in:
parent
275f39611d
commit
039f786e60
5 changed files with 22 additions and 43 deletions
|
|
@ -1,5 +1,4 @@
|
|||
{
|
||||
fnott-empty-settings = ./empty-settings.nix;
|
||||
fnott-example-settings = ./example-settings.nix;
|
||||
fnott-global-properties = ./global-properties.nix;
|
||||
fnott-systemd-user-service = ./systemd-user-service.nix;
|
||||
|
|
|
|||
|
|
@ -1,15 +0,0 @@
|
|||
{ config, lib, pkgs, ... }:
|
||||
|
||||
{
|
||||
config = {
|
||||
services.fnott = {
|
||||
enable = true;
|
||||
package = pkgs.writeScriptBin "dummy-fnott" "";
|
||||
settings = { };
|
||||
};
|
||||
|
||||
nmt.script = ''
|
||||
assertPathNotExists home-files/.config/fnott
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
[Service]
|
||||
BusName=org.freedesktop.Notifications
|
||||
ExecStart=@fnott@/bin/fnott -c /home/hm-user/.config/fnott/fnott.ini
|
||||
ExecStart=@fnott@/bin/fnott -c '/home/hm-user/.config/fnott/fnott.ini'
|
||||
Type=dbus
|
||||
|
||||
[Unit]
|
||||
|
|
|
|||
|
|
@ -8,8 +8,6 @@
|
|||
};
|
||||
|
||||
nmt.script = ''
|
||||
assertPathNotExists home-files/.config/fnott/fnott.ini
|
||||
|
||||
assertFileContent \
|
||||
home-files/.config/systemd/user/fnott.service \
|
||||
${./systemd-user-service-expected.service}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue