Skip to content

Commit 8cb3fcc

Browse files
eapolinarioclaude
andcommitted
feat(home): add xremap with Chromium Emacs keybindings
Adds xremap as a home-manager user service with wlroots/Hyprland support. Remaps C-a/e/f/b/n/p/d to Emacs-style navigation, scoped to Chromium only. Adds eduardo to the input group for device access. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent d6d7f6e commit 8cb3fcc

File tree

3 files changed

+31
-1
lines changed

3 files changed

+31
-1
lines changed

nixos/flake.nix

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,11 @@
2020
url = "github:nix-community/home-manager";
2121
inputs.nixpkgs.follows = "nixpkgs";
2222
};
23+
24+
xremap-flake = {
25+
url = "github:xremap/nix-flake";
26+
inputs.nixpkgs.follows = "nixpkgs";
27+
};
2328
};
2429

2530
outputs = { self, nixpkgs, disko, home-manager, ... }@inputs:
@@ -34,7 +39,9 @@
3439
home-manager.useGlobalPkgs = true;
3540
home-manager.useUserPackages = true;
3641
home-manager.extraSpecialArgs = { inherit inputs; };
37-
home-manager.users.eduardo = import ./home/eduardo;
42+
home-manager.users.eduardo = {
43+
imports = [ inputs.xremap-flake.homeManagerModules.default ./home/eduardo ];
44+
};
3845
}
3946
./hosts/${hostname}
4047
./modules/common

nixos/home/eduardo/default.nix

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,4 +165,26 @@
165165
};
166166

167167
programs.home-manager.enable = true;
168+
169+
services.xremap = {
170+
enable = true;
171+
withWlroots = true;
172+
config = {
173+
keymap = [
174+
{
175+
name = "Chromium Emacs bindings";
176+
application.only = [ "chromium" ];
177+
remap = {
178+
"C-a" = "Home";
179+
"C-e" = "End";
180+
"C-f" = "right";
181+
"C-b" = "left";
182+
"C-n" = "down";
183+
"C-p" = "up";
184+
"C-d" = "delete";
185+
};
186+
}
187+
];
188+
};
189+
};
168190
}

nixos/hosts/fusion-vm/default.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
programs.uwsm.enable = true;
2121

2222
users.users.eduardo.shell = pkgs.nushell;
23+
users.users.eduardo.extraGroups = [ "input" ];
2324

2425
# Display manager
2526
services.greetd = {

0 commit comments

Comments
 (0)