Works the same as M-b for me (backwards-word)
Make sure your /etc/inputrc or ~/.inputrc contains
# mappings for Ctrl-left-arrow and Ctrl-right-arrow for word moving "\e[1;5C": forward-word "\e[1;5D": backward-word "\e[5C": forward-word "\e[5D": backward-word "\e\e[C": forward-word "\e\e[D": backward-word`
Commenting to save. Thank you!
Idk if you know but you van actually save a post or comment pressing the button “save” under it. It will appear in your profile in a section of saved stuff.
Didn’t know that. My lemmy app doesn’t have a comment save button.
Lemmy:
> meme with problem
> SolutionCommentMemeCommentCommentMemeQuestion
Others:
> meme with problem
> BotCommentCommentAwardsAwardsBotShitpostAwardsShitpost
I hope the formatting shows properly… And thanks for this 😁 now to update the .inputrc on my laptop and VPSes
Edit: fix typo and formatting
Ctrl+a - go to beginning of line (alpha? I dunno)
ctrl+e - go to (e)nd of the line
alt+f - (f)orward one word
alt+b - (b)ack one word
You might already know these but no one else has posted them on this thread yet. I work in both Linux and Mac a lot and this works for them. No idea about Windows I’m no longer forced to use it at work 🙂
Also
Ctrl + w
to delete one word backwards (which is what OP wants to do).Edit: Nvm I misread the post, deleting is not what OP wants to do. Still gonna keep this because
Ctrl + w
is easily the readline shortcut I use the most.If you use WSL (which you should), you have a normal Bash, so it works
The best part of Windows is the part that isn’t Windows lmao lawd I’m glad I don’t work for the federal government (exclusively Microsoft) anymore
fed detected
In a sane editor just press
b
.Is Ctrl + ⬅️ for typing ‘b’ then?
No (although you can easily create such a key mapping if so inclined). To type b character one must first enter the so called Insert mode. Depending on where exactly you wish to type the character, you can enter the Insert mode by typing for example i, a, I, A, o or O.
It wasn’t a serious question 🙂
Sounds like you’re talking about good old vi or vim.
b
deleted by creator
Ctrl+backspace to delete previous word.
Ctrl+delete to delete next work.It also works with Shift so you can highlight and select words at a time.
Hey, I actually knew that shortcut! But it never occurred to me that ctrl+arrow just moves the cursor without selecting anything.
wild stuff.
What happens to me is the opposite. I got used to Ctrl+w to delete a word in terminal and accidentally closed browser tabs many times while typing in them.
Depends on the terminal. xfce4-terminal it works.
Works in the Cinnamon terminal, too.
And it works in QTerminal.
That’s why my terminal is emacs
I think you mean OS
That’s why my terminal is OS
Emacs and bash use the same navigation shortcuts though, LOL.
Bold of you to assume that an Emacs user will have anything remotely resembling the default keymap by the time they’re proud enough to brag about it
Idk about bash but at least in fish I can do alt + arrows to move the cursor by word, also alt + backspace works to delete whole words.
✨🌈 R E A D L I N E 🌈✨
I’ve never used a distro that didn’t come with a sane default shell config to avoid this
Does anyone know how to fix it in bash?
apt install fish
You didn’t read my comment properly :(
deleted by creator
fish is nice but the nonstandard syntax gets really annoying after a while. I use ble.sh these days.
I have no such weakness because I never learned bash syntax anyway.
It works for me, which terminal are you using?
What happens to me is the opposite. I got used to Ctrl+w to delete a word in terminal and accidentally closed browser tabs many times while typing in them.
SO TRUE OMG, also why the hell does it have to use ctrl + shift for shortcuts aaaa
CTRL-C has been the default key combination to terminate a running process, since forever. Reassigning it to “copy selection” would be very inconvenient.
I like the solution of the ElementaryOS terminal: when you press CTRL-C, it does “the right thing” depending on the context.
ohhh shoot thats cool! ty for the info :)
readline vim mode would like to have a word…