From 582d9a393900b9c7c6786c596d037c5a7fc73b1f Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Mon, 19 Jul 2021 22:01:05 -0600 Subject: [PATCH 1/3] Revert "[NixOS] Fix keyboard configuration compilation" This reverts commit dd441126be1fa2285612ef852308e84967a3da04. --- nixos/base.nix | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/nixos/base.nix b/nixos/base.nix index 75c5766b..7eb17aa9 100644 --- a/nixos/base.nix +++ b/nixos/base.nix @@ -87,15 +87,27 @@ xkbOptions = "ctrl:swapcaps"; layout = "us+rwin_as_hyper"; - extraLayouts.rwin_as_hyper = { + extraLayouts.hyper = { description = "Right Alt as Hyper key"; languages = [ ]; - symbolsFile = pkgs.writeText "rwin_as_hyper" '' + symbolsFile = pkgs.writeText "hyper" '' partial modifier_keys xkb_symbols "rwin_as_hyper" { replace key { [ Hyper_R ] }; modifier_map Mod3 { , Hyper_L, Hyper_R }; }; + + partial modifier_keys + xkb_symbols "home_as_hyper" { + replace key { [ Hyper_L ] }; + modifier_map Mod3 { , Hyper_L, Hyper_R }; + }; + + partial modifier_keys + xkb_symbols "ralt_as_hyper" { + replace key { [ Hyper_L, Hyper_L ] }; + modifier_map Mod3 { , Hyper_L }; + }; ''; }; From f4f0a7204b8b70b657f0fb8ca2205d83566463aa Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Mon, 19 Jul 2021 22:01:28 -0600 Subject: [PATCH 2/3] Revert "[NixOS] Set custom keyboard modifiers globally" This reverts commit 691d7835e3be6d7231c650e9b05997e878035cad. --- nixos/base.nix | 33 +++++---------------------------- nixos/home-manager.nix | 3 ++- 2 files changed, 7 insertions(+), 29 deletions(-) diff --git a/nixos/base.nix b/nixos/base.nix index 7eb17aa9..b4d32fb0 100644 --- a/nixos/base.nix +++ b/nixos/base.nix @@ -61,10 +61,12 @@ hardware.bluetooth.enable = true; services.blueman.enable = true; + # Keyboard/Keymap + console.keyMap = "us"; + i18n = { defaultLocale = "en_US.UTF-8"; }; - console.useXkbConfig = true; # Update timezone automatically services.tzupdate.enable = true; @@ -83,34 +85,9 @@ hardware.keyboard.zsa.enable = true; services.xserver = { + exportConfiguration = true; enable = true; - - xkbOptions = "ctrl:swapcaps"; - layout = "us+rwin_as_hyper"; - extraLayouts.hyper = { - description = "Right Alt as Hyper key"; - languages = [ ]; - symbolsFile = pkgs.writeText "hyper" '' - partial modifier_keys - xkb_symbols "rwin_as_hyper" { - replace key { [ Hyper_R ] }; - modifier_map Mod3 { , Hyper_L, Hyper_R }; - }; - - partial modifier_keys - xkb_symbols "home_as_hyper" { - replace key { [ Hyper_L ] }; - modifier_map Mod3 { , Hyper_L, Hyper_R }; - }; - - partial modifier_keys - xkb_symbols "ralt_as_hyper" { - replace key { [ Hyper_L, Hyper_L ] }; - modifier_map Mod3 { , Hyper_L }; - }; - ''; - }; - + layout = "us"; desktopManager = { plasma5.enable = true; }; diff --git a/nixos/home-manager.nix b/nixos/home-manager.nix index 94966c2e..d6f338e0 100644 --- a/nixos/home-manager.nix +++ b/nixos/home-manager.nix @@ -2,10 +2,11 @@ xsession = { enable = true; preferStatusNotifierItems = true; - importedVariables = [ "GDK_PIXBUF_ICON_LOADER" "PATH" ]; + importedVariables = [ "GDK_PIXBUF_ICON_LOADER" ]; profileExtra = '' export ROFI_SYSTEMD_TERM="alacritty -e" . "$HOME/.lib/login.sh" + load_xkb_map.sh ''; }; From bb080a73179eb7d645dc068317fa4ea122475de6 Mon Sep 17 00:00:00 2001 From: Ivan Malison Date: Tue, 20 Jul 2021 16:16:29 -0600 Subject: [PATCH 3/3] [NixOS] Bump home-manage --- nixos/home-manager | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nixos/home-manager b/nixos/home-manager index 1b533ee0..39cb571a 160000 --- a/nixos/home-manager +++ b/nixos/home-manager @@ -1 +1 @@ -Subproject commit 1b533ee0c5407df22334d66ab400f8f6c33b2d89 +Subproject commit 39cb571ad798a6e355e181d53bb513bfafa8c3be