diff options
| author | Emily <vcs@emily.moe> | 2023-08-03 02:28:06 +0100 |
|---|---|---|
| committer | Emily <vcs@emily.moe> | 2024-06-13 11:54:58 +0100 |
| commit | 09e72ff9b9a2d888aac70bc8019e5a0696f4c24c (patch) | |
| tree | 13bd682cff70d1acc98796f0541f679ecf992374 /modules | |
| parent | eb2f62d0de9997b2f73b409a2843ac5968e1a6f3 (diff) | |
fonts: remove `with lib`
Diffstat (limited to 'modules')
| -rw-r--r-- | modules/fonts/default.nix | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/modules/fonts/default.nix b/modules/fonts/default.nix index 7140639..cde6148 100644 --- a/modules/fonts/default.nix +++ b/modules/fonts/default.nix @@ -1,19 +1,17 @@ { config, lib, pkgs, ... }: -with lib; - let cfg = config.fonts; in { imports = [ - (mkRenamedOptionModule [ "fonts" "enableFontDir" ] [ "fonts" "fontDir" "enable" ]) + (lib.mkRenamedOptionModule [ "fonts" "enableFontDir" ] [ "fonts" "fontDir" "enable" ]) ]; options = { - fonts.fontDir.enable = mkOption { - type = types.bool; + fonts.fontDir.enable = lib.mkOption { + type = lib.types.bool; default = false; description = '' Whether to enable font management and install configured fonts to @@ -23,10 +21,10 @@ in ''; }; - fonts.fonts = mkOption { - type = types.listOf types.path; + fonts.fonts = lib.mkOption { + type = lib.types.listOf lib.types.path; default = [ ]; - example = literalExpression "[ pkgs.dejavu_fonts ]"; + example = lib.literalExpression "[ pkgs.dejavu_fonts ]"; description = '' List of fonts to install. @@ -48,7 +46,7 @@ in done ''; - system.activationScripts.fonts.text = optionalString cfg.fontDir.enable '' + system.activationScripts.fonts.text = lib.optionalString cfg.fontDir.enable '' # Set up fonts. echo "configuring fonts..." >&2 find -L "$systemConfig/Library/Fonts" -type f -print0 | while IFS= read -rd "" l; do |
