Keep your xmodmaps in ~/.Xmodmaps/
and this utility will find
the next map file and replace your ~/.Xmodmap
.
- Looks for files in
~/.Xmodmaps/
- Finds the next .Xmodmap file
- Creates a diff between current and new
- Executes
xmodmap
- Copies the content for the next Xmodmap file into
~/.Xmodmap
Using xmodmap
on only changed keycodes is a lot faster.
- Better error handling
- Replace PHP code with Rust
mkdir ~/.Xmodmaps
cp ~/.Xmodmap ~/.Xmodmaps/
git clone https://github.com/eigan/xmodmapswitch.git
bindcode <keycode> exec php <path/to/project>/xmodmapswitch.php