Skip to contentSkip to conversation

Update `test` '-a' and '-o' to '&&' and '||'

DISCUSSION GitHub pull_request - opened 1 participant 1 message Apr 29, 2023 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw

alsa-project/alsa-utils pull request #206 was opened from wileyhy:

lines 50, 103: in two compound ['s, replace '-a' with '] && ['
SC2166 – Prefer [ p ] && [ q ] as [ p -a q ] is not well defined. SC2107 – Instead of [ a && b ], use [ a ] && [ b ].

line 45: in a compound test command, change '-o' to '|| test'
SC1139 – Use || instead of -o between test commands. SC2109 – Instead of [ a || b ], use [ a ] || [ b ].

https://www.shellcheck.net/wiki/SC[0-9]{4}

Request URL : https://github.com/alsa-project/alsa-utils/pull/206
Patch URL : https://github.com/alsa-project/alsa-utils/pull/206.patch
Repository URL: https://github.com/alsa-project/alsa-utils