5 ms·
> You know how sometimes if you mistype a filename in Bash, it corrects your spelling and runs the command anyway? What? No, what's that about?
by Bromskloss 9y ago
> You know how sometimes if you mistype a filename in Bash, it corrects your spelling and runs the command anyway?
What? No, what's that about?
- atdt 9y agoThere's the cdspell shopt: "If set, minor errors in the spelling of a directory component in a cd command will be corrected. The errors checked for are transposed characters, a missing character, and a character too many. If a correction is found, the corrected path is printed, and the command proceeds." (https://www.gnu.org/software/bash/manual/html_node/The-Shopt-Builtin.html https://www.gnu.org/software/bash/manual/html_node/The-Shopt...)
- dfc 9y agoThat's for `cd smoedir` I am not aware of what would do `./smoeexec`
- bobbyi_settv 9y agoIt's an interesting idea, but is made mostly irrelevant by tab completion.
- ihaveajob 9y agoI knew a guy who aliased all permutations of 'make' (maek, mkae, amke...) to 'make', so he just hammer the keys at once and be sure the thing would run.
- knodi123 9y agoI've had to do this with grep, gerp gpre gper. I've determined that I'm just constitutionally incapable of typing that word more than 2 in 3 times, and I've learned to cope with my disability.
- Jedd 9y ago> What? No, what's that about? From TFA: "Update 2015-04-18 -- I suppose I should finally clear this up: The autocorrect functionality I originally described here was a feature of the first Linux systems I ever used, so I assumed it was how every Linux system worked by default. Since then I've come to understand that it's a completely optional extra doodad."
- pierrec 9y agoYeah, I'm not aware of any distro that has this setting enabled by default. It's neat that it exists, though.
- nitrogen 9y agoDistros in the late 90s were a lot more adventurous in their defaults as I recall.