From 46398fc688c746fc02c74e4605a27d0936e9bd8c Mon Sep 17 00:00:00 2001 From: Ryan Yin Date: Mon, 6 Jul 2026 22:01:18 +0800 Subject: [PATCH] fix(nixos): migrate kmscon to config attrset Nixpkgs removed services.kmscon.fonts and services.kmscon.extraConfig, so the old font module failed evaluation on current nixos-unstable. Move the selected font, font size, and hardware acceleration settings into services.kmscon.config while keeping the existing terminal type option. --- modules/nixos/desktop/fonts.nix | 18 +++++------------- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/modules/nixos/desktop/fonts.nix b/modules/nixos/desktop/fonts.nix index d9487595..84820f7c 100644 --- a/modules/nixos/desktop/fonts.nix +++ b/modules/nixos/desktop/fonts.nix @@ -55,19 +55,11 @@ # It supports a richer feature set than the standard linux console VT, # including full unicode support, and when the video card supports drm should be much faster. enable = true; - fonts = with pkgs; [ - { - name = "Maple Mono NF CN"; - package = maple-mono.NF-CN-unhinted; - } - { - name = "JetBrainsMono Nerd Font"; - package = nerd-fonts.jetbrains-mono; - } - ]; extraOptions = "--term xterm-256color"; - extraConfig = "font-size=14"; - # Whether to use 3D hardware acceleration to render the console. - hwRender = true; + config = { + font-name = "Maple Mono NF CN"; + font-size = 14; + hwaccel = true; + }; }; }