I've seen and read about zsh offering auto correction of a command input. Eg- if I type sl, it should ask me something like "did you mean ls?" But, in my zsh, this does not happen. It just gives an error. Is there a reason for this, some settings maybe? (And yes, I'm sure that I'm running zsh and not bash or something)
1 Answer
This is controlled by the CORRECT
option, see zshoptions(1)
.
% zsh -f
dhcp196-230% setopt correct
dhcp196-230% sl
zsh: correct 'sl' to 'ls' [nyae]? y
...
dhcp196-230% setopt nocorrect
dhcp196-230% sl
zsh: command not found: sl
dhcp196-230%