From a689375bb0928f211460432e04013600b2303bab Mon Sep 17 00:00:00 2001 From: notohh Date: Fri, 31 Mar 2023 18:15:58 -0400 Subject: [PATCH] feat: init fonts.nix module --- hosts/hime/default.nix | 8 ++++--- hosts/tsuki/default.nix | 53 +++++++++++------------------------------ modules/default.nix | 1 + modules/fonts.nix | 34 ++++++++++++++++++++++++++ 4 files changed, 54 insertions(+), 42 deletions(-) create mode 100644 modules/fonts.nix diff --git a/hosts/hime/default.nix b/hosts/hime/default.nix index d0c1d0a..24fa78f 100644 --- a/hosts/hime/default.nix +++ b/hosts/hime/default.nix @@ -1,6 +1,8 @@ -{ config, pkgs, ... }: - -{ +{ + config, + pkgs, + ... +}: { imports = [ ./hardware-configuration.nix diff --git a/hosts/tsuki/default.nix b/hosts/tsuki/default.nix index a824369..ac8c72a 100755 --- a/hosts/tsuki/default.nix +++ b/hosts/tsuki/default.nix @@ -1,6 +1,8 @@ -{ config, pkgs, inputs, ... }: - -{ +{ + config, + pkgs, + ... +}: { imports = [ ./hardware-configuration.nix @@ -26,11 +28,15 @@ virtualisation.libvirtd.enable = true; - networking.hostName = "tsuki"; + networking = { + networkmanager.enable = true; + nameservers = [ "192.168.1.45" ]; + hostName = "tsuki"; + firewall = { + enable = true; + }; + }; - networking.networkmanager.enable = true; - networking.nameservers = [ "192.168.1.45" ]; - # pihole environment.etc = { "resolv.conf".text = "nameserver 192.168.1.45\n"; @@ -61,11 +67,6 @@ videoDrivers = [ "nvidia" ]; layout = "us"; xkbVariant = ""; - displayManager = { - lightdm = { - enable = false; - }; - }; }; }; @@ -153,33 +154,7 @@ python310Packages.python-lsp-server ]; - fonts = { - enableDefaultFonts = true; - fontDir.enable = true; - fonts = with pkgs; [ - inter - jetbrains-mono - nerdfonts - noto-fonts-cjk-sans - twemoji-color-font - font-awesome - fira-code-symbols - kochi-substitute - ipafont - ]; - - fontconfig = { - enable = true; - allowBitmaps = true; - defaultFonts = { - monospace = ["JetBrainsMono Nerd Font"]; - sansSerif = ["Google Sans Text"]; - }; - hinting.style = "hintfull"; - }; - }; - - nix = { + nix = { package = pkgs.nixFlakes; extraOptions = '' experimental-features = nix-command flakes diff --git a/modules/default.nix b/modules/default.nix index 7640736..d1dbe06 100644 --- a/modules/default.nix +++ b/modules/default.nix @@ -6,5 +6,6 @@ ./tailscale.nix ./security.nix ./udevd.nix + ./fonts.nix ]; } diff --git a/modules/fonts.nix b/modules/fonts.nix new file mode 100644 index 0000000..af341b9 --- /dev/null +++ b/modules/fonts.nix @@ -0,0 +1,34 @@ +{ + pkgs, + ... +}: { + + fonts = { + enableDefaultFonts = false; + fontDir.enable = true; + fonts = with pkgs; [ + inter + jetbrains-mono + nerdfonts + noto-fonts-cjk-sans + twemoji-color-font + font-awesome + fira-code-symbols + kochi-substitute + ipafont + ]; + + fontconfig = { + enable = true; + allowBitmaps = true; + defaultFonts = { + monospace = ["JetBrainsMono Nerd Font"]; + sansSerif = ["Noto Sans" "Noto Color Emoji"]; + emoji = ["Twitter Color Emoji"]; + }; + + hinting.style = "hintfull"; + + }; + }; +}