In all GUI text editors, web browsers and IDE’s you can move a cursor:
- left/right arrows - move by char;
- ctrl+left/right - move by word;
- home/end - move to start/end of line.
Add Shift to any of above combination and everything you jumped through now is selected and you can: Ctrl+C, Ctrl+X,Delete to copy/cut/delete selection.
Also, you can Ctrl+Delete and Ctrl+Backspace to delete a next/previous word.
Also, you can Ctrl+Home/End to jump to start of first line or end of last line.
I want this to work when I type in a command in my Terminal.
Is it possible in Linux? It’s a vanilla experience in Windows+Powershell, thanks to default PSReadlLine extension. It works both in conhost.exe and in Windows Terminal, but doesn’t work in WT + cmd.exe, which makes me think it’s PSReadLine which is responsible for this technological perfection.
“But you can’t copy with Ctrl+C, it’s…” - You can. When something is selected It copies selection to clipboard, otherwise it sends SIGINT.
I’m not bound to any distro or terminal application, but right now I don’t see these incredible text editing techniques working even in Ubuntu+Powershell+PSReadLine, to say nothing about the Bash. I’ve tried installing WezTerm, but it doesn’t have text selection either, at least by default. And I’m inclined to think it has nothing to do with terminal emulators at all, since it works in conhost.exe+Powershell.


Here it is. What I’m asking for is not sophisticated at all, quite the opposite. I ask for keybindings which work in almost all text editing areas, in all applications, all operating systems. Vi and eMacs are steps in opposite direction. I think I even used a vi-mode in terminal a couple of years ago. I doubt it’s possible to simplify command editing with it.
The thing is that vi and emacs have existed since long before those other new editors came around.
What you want is possible to do by configuring your
~/.inputrc(see readline manual page for details), it’s just that the defaults are different because they are from a time when many keyboards didn’t even have arrow keys (and the ones that had them were in non-standard positions) so most of the shortcuts that became standard in those days are completely different than the ones common today. Given that the terminal is meant to emulate old style DEC VT100 terminals (that’s why it’s called terminal “emulator”) it made sense to use those default that people had grown used to.Personally, I’ve grown used to Ctrl+a, Ctrl+k, Ctrl+w, Ctrl+e and Ctrl+y …I dont have to reach to wherever the Home key is in whatever keyboard I happen to be using at the moment (specially with modern 75%/60%-sized keyboards today). Or use a combination that also requires shift and having to hold so many keys together. In fact I went the opposite direction and customized my Powershell profile while I’m on windows to keep many of those old shortcuts in the Windows pwsh terminal as well.
What a weird thing to say… So what that they existed before? Who cares?
Ctrl/Shift modifiers work in a very consistent way in the entirety of Windows, most of Mac, and… everywhere in Linux except the terminal.
It boggles my mind that there isn’t a simple switch to toggle between “classic” and “modern” style for keybinds.
deleted by creator
Do I need to record a screencap from conhost.exe for you to believe me when I say you’re wrong?
Where did that come from? I never said anything about tab completion or “etc”. I was talking specifically about Ctrl/Shift combinations with arrows/backspace/home/end, and such.
Did you even read what I wrote? I said that there should be an option to switch between “modern” and “classic” keybinds. With the default being set to “classic” everywhere, how exactly would that cause any problems for you?
Mate, are you high? That’s what the OP is asking for. Do you know any such terminal emulators? Post some names!