summary refs log tree commit diff stats
path: root/modules/nixos
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--modules/nixos/sils/default.nix1
-rw-r--r--modules/nixos/sils/font.nix25
-rw-r--r--modules/nixos/sils/roles.nix1
3 files changed, 27 insertions, 0 deletions
diff --git a/modules/nixos/sils/default.nix b/modules/nixos/sils/default.nix
index 9324c46..7135ff9 100644
--- a/modules/nixos/sils/default.nix
+++ b/modules/nixos/sils/default.nix
@@ -3,6 +3,7 @@
     ./basesystem.nix
     ./bluetooth.nix
     ./environment.nix
+    ./font.nix
     ./hyprland.nix
     ./meta.nix
     ./networking.nix
diff --git a/modules/nixos/sils/font.nix b/modules/nixos/sils/font.nix
new file mode 100644
index 0000000..879459d
--- /dev/null
+++ b/modules/nixos/sils/font.nix
@@ -0,0 +1,25 @@
+{
+  config,
+  lib,
+  pkgs,
+  ...
+}: let
+  cfg = config.sils.font;
+in {
+  options.sils.font.enable = lib.mkEnableOption "font config";
+  config = lib.mkIf cfg.enable {
+    fonts = {
+      packages = with pkgs; [
+        nerdfonts
+      ];
+      fontconfig = {
+        defaultFonts = {
+          # serif = ["Vazir"];
+          # sansSerif = ["Vazir"];
+          monospace = ["SourceCodePro"];
+        };
+      };
+      fontDir.enable = true;
+    };
+  };
+}
diff --git a/modules/nixos/sils/roles.nix b/modules/nixos/sils/roles.nix
index 8ab2df3..e973759 100644
--- a/modules/nixos/sils/roles.nix
+++ b/modules/nixos/sils/roles.nix
@@ -7,6 +7,7 @@ in {
       basesystem.enable = true;
       bluetooth.enable = true;
       environment.enable = true;
+      font.enable = true;
       hyprland.enable = true;
       networking.enable = true;
       nix-config.enable = true;