Hacker News new | ask | show | jobs
by hackeraccount 234 days ago
I'm terrible about remembering shortcuts (edit a bash line in an editor? Can never remember it) but clear (CTRL-l) is one that really stuck.

That and exit (CTRL-d). A guy I used to work with just mentioned it casually and someone it just seared itself into my brain.

2 comments

FYI, ctrl-d isn't a shortcut to exit terminal. It sends EOF (end of file) character which, when reaches shell, closes stdinput file of shell. It generally closes any active interactive input, like all repls, interactive input to sed etc. When interactive shell loses possibility to get more input, it closes as soon as possible and then its parent, the terminal window, also closes. More-less :)
Never new ctrl+l, that's great, thanks!