prefer [[ over [ for multiple conditionals

Co-authored-by: Jonas Chevalier <zimbatm@zimbatm.com>
This commit is contained in:
Raphael Megzari 2021-06-26 12:55:08 +09:00
parent 9f156d0adc
commit db78412f25

View file

@ -6,7 +6,7 @@ preFixupHooks+=(_moveToShare)
_moveToShare() {
forceShare=${forceShare:=man doc info}
if [ -z "$forceShare" ] || [ -z "$out" ]; then return; fi
if [[ -z "$forceShare" || -z "$out" ]]; then return; fi
for d in $forceShare; do
if [ -d "$out/$d" ]; then
@ -20,4 +20,3 @@ _moveToShare() {
fi
done
}