feat(x1): enhance xremap configuration

- Added user `harald` to the `input` group for proper permissions.
- Introduced device-specific configuration using `services.xremap.deviceNames`.
- Refined key remapping structure by aligning with `keymap` format.
This commit is contained in:
Harald Hoyer 2025-12-15 11:37:12 +01:00
parent a1ff322926
commit 5b5c44386c

View file

@ -1,15 +1,26 @@
# In /etc/nixos/configuration.nix
{ ... }:
{
users.users.harald.extraGroups = [ "input" ];
# Enable the xremap service
services.xremap.enable = true;
services.xremap.userName = "harald"; # Replace with your username
services.xremap.serviceMode = "user"; # Run as user service, not system-wide
services.xremap.withGnome = true;
# Add a specific configuration block to select your keyboard(s) by name
services.xremap.deviceNames = [
# Use the name found in the log output: "Hangsheng MonsGeek Keyboard System Control"
"Hangsheng MonsGeek Keyboard"
# You can usually shorten the name slightly to match the device you want
];
# Define your remapping configuration using Nix's attribute set format
services.xremap.config = {
global_remaps = [
keymap = [
{
remap = {
# Map Alt+C (LeftAlt-C) to Ctrl+C (LeftControl-C)