feat: add defaultApplication and startupApplications options
This commit is contained in:
parent
fc2638152d
commit
7c0d62d2b1
@ -6,7 +6,14 @@ let
|
|||||||
mapAttrs
|
mapAttrs
|
||||||
readDir
|
readDir
|
||||||
;
|
;
|
||||||
inherit (lib) hasSuffix remove;
|
inherit (lib) hasSuffix mkOption remove;
|
||||||
|
inherit (lib.types)
|
||||||
|
attrsOf
|
||||||
|
listOf
|
||||||
|
path
|
||||||
|
str
|
||||||
|
submodule
|
||||||
|
;
|
||||||
|
|
||||||
filterRoot = remove (./. + "/default.nix");
|
filterRoot = remove (./. + "/default.nix");
|
||||||
|
|
||||||
@ -35,4 +42,27 @@ let
|
|||||||
in
|
in
|
||||||
{
|
{
|
||||||
imports = filterRoot (findModules ./.);
|
imports = filterRoot (findModules ./.);
|
||||||
|
|
||||||
|
options = {
|
||||||
|
defaultApplications = mkOption {
|
||||||
|
default = { };
|
||||||
|
type = attrsOf (
|
||||||
|
submodule (
|
||||||
|
{ ... }:
|
||||||
|
{
|
||||||
|
options = {
|
||||||
|
cmd = mkOption { type = path; };
|
||||||
|
desktop = mkOption { type = str; };
|
||||||
|
};
|
||||||
|
}
|
||||||
|
)
|
||||||
|
);
|
||||||
|
description = "Preferred applications";
|
||||||
|
};
|
||||||
|
|
||||||
|
startupApplications = mkOption {
|
||||||
|
type = listOf str;
|
||||||
|
description = "Applications to run on startup";
|
||||||
|
};
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user