

Show HN: Tip – use ctrl and w to rapid delete in terminal / shell - abpai

hours of life saved :)
======
jdmoreira
[https://github.com/0nn0/terminal-mac-
cheatsheet/wiki/Termina...](https://github.com/0nn0/terminal-mac-
cheatsheet/wiki/Terminal-Cheatsheet-for-Mac-\(-basics-\))

~~~
cwt
This is glorious!

------
stevekemp
This handling comes from readline, rather than your terminal/shell.

Readline has many shortcuts available here's a random assortment:

[http://teohm.com/blog/2012/01/04/shortcuts-to-move-faster-
in...](http://teohm.com/blog/2012/01/04/shortcuts-to-move-faster-in-bash-
command-line/)

~~~
ksherlock
^W, ^U, ^C, ^S, ^Q, ^Z, etc are handled by the terminal driver. See stty -a

------
wsc981
Useful tip. Made me realise ctrl-s works to go to start of line and ctrl-e to
end of line. This is probably common knowledge for any Linux user but for me
as a Mac user it's a revelation.

~~~
amk_
You mean ctrl-a for beginning-of-line?

~~~
atsaloli
Yeah, it's ctrl-A for start of line.

Here's a good cheatsheet:
[http://www.bigsmoke.us/readline/shortcuts](http://www.bigsmoke.us/readline/shortcuts)

------
nstart
Thank you! Didn't know this till today.

