modules: fix state.paths typing

This commit is contained in:
Gabriel Arazas 2024-08-02 11:55:21 +08:00
parent c3cdc27721
commit 6987a2215f
No known key found for this signature in database
GPG Key ID: 62104B43D00AA360
3 changed files with 4 additions and 4 deletions

View File

@ -6,7 +6,7 @@
pathsSubmodule = { lib, ... }: { pathsSubmodule = { lib, ... }: {
options = { options = {
paths = lib.mkOption { paths = lib.mkOption {
type = with lib.types; attrsOf (listOf path); type = with lib.types; attrsOf (listOf str);
default = { }; default = { };
description = '' description = ''
Set of paths to hold as a single source of truth for path-related Set of paths to hold as a single source of truth for path-related
@ -22,6 +22,6 @@
}; };
}; };
in lib.mkOption { in lib.mkOption {
type = lib.type.submodule pathsSubmodule; type = lib.types.submodule pathsSubmodule;
}; };
} }

View File

@ -108,7 +108,7 @@ in {
changeDirWidgetCommand = "${fd} --type directory --unrestricted"; changeDirWidgetCommand = "${fd} --type directory --unrestricted";
defaultCommand = "${fd} --type file --hidden"; defaultCommand = "${fd} --type file --hidden";
defaultOptions = let defaultOptions = let
skipDirectories' = lib.concatStringsSep "," config.state.ignoreDirectories; skipDirectories' = lib.concatStringsSep "," config.state.paths.ignoreDirectories;
in [ in [
"--walker-skip=${skipDirectories'}" "--walker-skip=${skipDirectories'}"
]; ];

View File

@ -6,7 +6,7 @@
directoriesSubmodule = { lib, ... }: { directoriesSubmodule = { lib, ... }: {
options = { options = {
paths = lib.mkOption { paths = lib.mkOption {
type = with lib.types; attrsOf (listOf path); type = with lib.types; attrsOf (listOf str);
description = '' description = ''
A set of directories to share its value to various parts of the A set of directories to share its value to various parts of the
system. system.