kbd service: use systemd-vconsole-setup even with early setup

This way we have fonts reloaded on switches.
This commit is contained in:
Nikolay Amiantov 2017-02-16 16:45:19 +03:00
parent bc2f53fd29
commit 109ee2a338

View File

@ -71,7 +71,7 @@ in
###### implementation ###### implementation
config = mkMerge [ config = mkMerge [
(mkIf (!setVconsole || (setVconsole && config.boot.earlyVconsoleSetup)) { (mkIf (!setVconsole) {
systemd.services."systemd-vconsole-setup".enable = false; systemd.services."systemd-vconsole-setup".enable = false;
}) })
@ -97,9 +97,7 @@ in
printf "${makeColorCS n color}" >> /dev/console printf "${makeColorCS n color}" >> /dev/console
'') config.i18n.consoleColors} '') config.i18n.consoleColors}
''; '';
}
(mkIf (!config.boot.earlyVconsoleSetup) {
systemd.services."systemd-vconsole-setup" = systemd.services."systemd-vconsole-setup" =
{ wantedBy = [ "sysinit.target" ]; { wantedBy = [ "sysinit.target" ];
before = [ "display-manager.service" ]; before = [ "display-manager.service" ];
@ -107,7 +105,7 @@ in
restartTriggers = [ vconsoleConf kbdEnv ]; restartTriggers = [ vconsoleConf kbdEnv ];
restartIfChanged = false; # fails when tty is inactive restartIfChanged = false; # fails when tty is inactive
}; };
}) }
(mkIf config.boot.earlyVconsoleSetup { (mkIf config.boot.earlyVconsoleSetup {
boot.initrd.extraUtilsCommands = '' boot.initrd.extraUtilsCommands = ''