The biggest problem I’ve had with micro has been getting used to its very CUA-like sensibility. Sticking these in ~/.config/micro/bindings.json
looks like it is relieving the worst of it, leaving me with a just-fine zippy little editor that doesn’t need Emacs infrastructure to operate.
{
"\u001b\u003c": "CursorStart",
"\u001b\u003e": "CursorEnd",
"\u003cCtrl-x\u003e\u003c0\u003e": "Unsplit",
"\u003cCtrl-x\u003e\u003c2\u003e": "HSplit",
"\u003cCtrl-x\u003e\u003c3\u003e": "VSplit",
"\u003cCtrl-x\u003e\u003cCtrl-c\u003e": "Quit",
"\u003cCtrl-x\u003e\u003cCtrl-f\u003e": "OpenFile",
"\u003cCtrl-x\u003e\u003cCtrl-s\u003e": "Save",
"\u003cCtrl-x\u003e\u003ch\u003e": "SelectAll",
"\u003cCtrl-x\u003e\u003co\u003e": "command:fzf",
"Alt-/": "lua:comment.comment",
"Alt-a": "lua:snippets.Accept",
"Alt-b": "WordLeft",
"Alt-d": "lua:snippets.Cancel",
"Alt-f": "WordRight",
"Alt-s": "lua:snippets.Insert",
"Alt-v": "CursorPageUp",
"Alt-w": "Copy",
"Alt-x": "CommandMode",
"Ctrl-a": "StartOfLine",
"Ctrl-e": "EndOfLine",
"Ctrl-g": "Escape",
"Ctrl-k": "CutLine",
"Ctrl-r": "FindPrevious",
"Ctrl-s": "Find",
"Ctrl-v": "CursorPageDown",
"Ctrl-y": "Paste",
"Ctrl-z": "Undo",
"CtrlP": "command:palettero",
"CtrlSpace": "command:palettero",
"CtrlUnderscore": "Undo",
"F1": "command:cheat",
"F12": "command:makeup",
"F4": "command:jumptag",
"F5": "command:runit",
"F9": "command:makeupbg"
}
I used to use jed for this, until something went wrong with it for a while. It seems to be operating correctly again to judge from my latest pull down from Homebrew, but I just went to this trouble with micro …
Anyhow, I realized a few things got left out there, so here’s a gist with a more complete set including Emacs-style C-_
undo and Alt-<
Alt->
top/bottom of the buffer.