compare:
#!/bin/bash
debug=1
tf=1
string="abc"
test $debug -eq 1 && {
echo "hello, test"
echo "hello, more"
}
if [ $debug = 0 ] || [ $tf -eq 0 ] || [ 0 ]; then
echo $string
fi
test $debug = 0 || {
string="`echo 123`"
}
echo $string
compare:
#!/bin/bash
debug=1
tf=1
string="abc"
test $debug -eq 1 && {
echo "hello, test"
echo "hello, more"
}
if [ $debug = 0 ] || [ $tf -eq 0 ] || [ 0 ]; then
echo $string
fi
test $debug = 0 || {
string="`echo 123`"
}
echo $string