Ventoy
Ventoy copied to clipboard
Fixes for running under dash 0.5.11.2 and POSIX (1003.2) fixes
For only the first fix lines 26->32 change "echo -en" to "printf" . Otherwise, when VentoryWorker.sh calls those functions all output produced by them is prefixed with "-e" because it is not defined in POSIX.
Other changes:
- Quotes where needed when globbing/word-splitting is undesired (will need review to ensure word-splitting is undesired)
- Replace expr with $((..))
- Replace egrep with grep -E (more portable)
- Replace echo -e with printf and separate format string (SC2039: In POSIX sh, echo flags are undefined)
This PR and the previous one I made earlier (regarding unexpected operator on line 45) both fix all issues I have had this morning using Ventoy in a POSIX (dash) environment.