Activity for mjy
Type | On... | Excerpt | Status | Date |
---|---|---|---|---|
Edit | Post #286124 | Initial revision | — | over 2 years ago |
Answer | — |
A: A shell script that can run under different shells I came up with three methods. Exit early Use `exit` early instead of the `elif` syntax. Basically shell is an interpreter. As soon as the parsing of the first `if` statement is finished, it will be executed. In this case, if shell is bash, `exit` before the parsing of the next `if` stateme... (more) |
— | over 2 years ago |