Light Emacs Bindings日本語版はこちら / Japanese version here → README.ja.md Ever had an Emacs keybinding extension quietly break copy-paste on you — working in one panel, dead in another? Not this one. Copy, Cut, and Paste stay exactly as VS Code intends, always, everywhere. This extension only adds the Emacs muscle memory that doesn't fight your editor — and anywhere a conflict truly can't be avoided, it's documented up front and can be switched off in one click. Policy
Keybindings by categoryMovement
Mark & selection
Search
File & editing
Commands
How
|
| VS Code default this replaces | Still reachable via |
|---|---|
Toggle Sidebar Visibility (Ctrl+B) |
View menu / Command Palette |
New File (Ctrl+N) |
File menu / Command Palette |
Quick Open (Ctrl+P) |
Ctrl+X Ctrl+F / Command Palette |
Find (Ctrl+F) |
Ctrl+S / Command Palette |
Go to Line (Ctrl+G) |
Command Palette |
Select All (Ctrl+A) |
Edit menu / Command Palette |
Trigger Suggest, manual (Ctrl+Space) |
Command Palette |
Toggle Line Comment (Ctrl+/) |
Ctrl+; |
Save (Ctrl+S) |
Ctrl+X Ctrl+S / File menu |
Switch Window/Workspace (Ctrl+R) |
Command Palette |
Ctrl+K … chord family |
Command Palette |
Copy, Cut, and Paste are never in this table — they're not touched.
Settings
Search "Light Emacs Bindings" in VS Code's Settings UI, or edit settings.json directly:
| Setting | Default | Controls |
|---|---|---|
lightEmacsBindings.enable |
true |
Master switch for every keybinding |
lightEmacsBindings.movement.enabled |
true |
Movement category |
lightEmacsBindings.mark.enabled |
true |
Mark (Ctrl+Space) |
lightEmacsBindings.rectangleSelection.enabled |
true |
Rectangle selection (Ctrl+X Space) |
lightEmacsBindings.goToFile.enabled |
true |
Go to file (Ctrl+X Ctrl+F) |
lightEmacsBindings.save.enabled |
true |
Save (Ctrl+X Ctrl+S) |
lightEmacsBindings.commandPalette.enabled |
true |
Command Palette (Alt+X) |
lightEmacsBindings.killLine.enabled |
true |
Kill-line (Ctrl+K) |
lightEmacsBindings.comment.enabled |
true |
Comment toggle (Ctrl+;) |
lightEmacsBindings.undoRedo.enabled |
true |
Undo/Redo (Ctrl+/ / Ctrl+Shift+/) |
lightEmacsBindings.incrementalSearch.enabled |
true |
Search (Ctrl+S / Ctrl+R) |
{
"lightEmacsBindings.movement.enabled": false,
"lightEmacsBindings.killLine.enabled": false
}
Bind your own toggle key
lightEmacsBindings.toggleEnabled ships with no default keybinding. Add one in keybindings.json:
{
"key": "ctrl+alt+e",
"command": "lightEmacsBindings.toggleEnabled"
}
Known limitations / Roadmap
- Keyboard macros are out of scope for v1. VS Code has no general-purpose macro-recording API and no way to intercept arbitrary command execution. A future version might offer a scoped recorder limited to this extension's own commands (movement, mark, rectangle selection, go-to-file, etc.) — that would be low-risk; a general one would not.
- If you disable only one of
rectangleSelection.enabled/goToFile.enabled/save.enabled, itsCtrl+Xfollow-up key falls through to that key's own VS Code default during the ~1 second window instead of doing nothing. Alt+F/Alt+Bmay collide with File-menu mnemonics if your menu bar is visible (no issue if it's hidden).
Requirements
- VS Code 1.85.0 or later.
Development
npm install # install dependencies
npm run compile # type-check, then bundle with esbuild
npm run watch # rebuild on save
npm test # run the vitest unit tests
npm run icon # regenerate images/icon.png from images/icon.svg
npm run package # produce a .vsix
Press F5 in VS Code to launch an Extension Development Host with this extension loaded.
Release
Push a v* tag to trigger .github/workflows/release.yml, which builds a .vsix and attaches it to a GitHub Release.
License
MIT — see LICENSE.