3 ms·
Nice article, it’s usually hard to keep a reader’s interest when writing about shell. I will nitpick that COMP_LINE et al are shell variables, not environment
by karatinversion 7y ago
Nice article, it’s usually hard to keep a reader’s interest when writing about shell.
I will nitpick that COMP_LINE et al are shell variables, not environment variables - you can tell by the fact you don’t need to export the “return value”. (Scare quotes, as the function’s exit code, manually specifiable with “return NN”, is also called its return value.)
- p_ronto 7y agoI think they are env vars. complete is a bash built-in. It is executed in the process of the shell. You only need to export for child processes.