Email or username:

Password:

Forgot your password?
Top-level
pelavarre

@b0rk @njvack

⌃W and ⌃U and ⌃Q and ⌃S and so on hide away deep inside: stty all

for example

$ stty -a
...
intr = ^C; quit = ^\; erase = ^?; kill = ^U; eof = ^D; eol = <undef>; eol2 = <undef>;
swtch = <undef>; start = ^Q; stop = ^S; susp = ^Z; rprnt = ^R; werase = ^W; lnext = ^V;
...
$

macOS

% stty -a
...
cchars: discard = ^O; dsusp = ^Y; eof = ^D; eol = <undef>;
eol2 = <undef>; erase = ^?; intr = ^C; kill = ^U; lnext = ^V;
min = 1; quit = ^\; reprint = ^R; start = ^Q; status = ^T;
stop = ^S; susp = ^Z; time = 0; werase = ^W;
%

part of how you can test for this is to try inside of: cat -

the ⌃W and ⌃U will work there, even when Arrow Keys etc don't work there

<=

macOS lets you spell out 'stty -a' as 'stty all', but Linux doesn't

Linux lets you abbreviate 'stty -a' as 'stty --all', but macOS doesn't

'stty -a' reports the 'stty ixon' vs 'stty -ixon' toggle in a different output line apart from these mentions of ^Q ^S, but you often need to add 'stty -ixon' to make the ⌃S forward-search-history properly undo
the ^R reverse-search-history mentioned
by Bash bind -p |grep C-[rs]
or the ^R history-incremental-search-backward
by Zsh bindkey |grep '\^[RS]'

i can't remember how often Zsh needs this workaround = maybe less often than Bash

1 comment
pelavarre

⌃W and ⌃U are not precisely ^W and ^U, because "^" is pure Ascii and more classic, but ⌃ is the Unicode Up Arrowhead U+2303 that's part of ⌃ ⌥ ⇧ ⌘ ← ↑ → ↓ ⎋ ⏎ ⇥ ⇤

Go Up