Mixed shell test styles
hpwxf opened this issue · 2 comments
hpwxf commented
In travis-ci shell script, there are two styles for tests:
- One bracket style
if [ "$VALGRIND" = true ]; then
- Two brackets style
if [[ "$SONAR" == true ]]; then
The first one is POSIX compliant and the second one is more flexible by only support by ks, bash and zsh.
Should we define a reference style?
Notes:
RUrlus commented
Going by the stack overflow answer I would argue that the two brackets style is preferred as portability is not a major concern here.