if -r bash code example
Example 1: if and if bash
if [ "${STATUS}" != 200 ] && [ "${STRING}" != "${VALUE}" ]; then
Example 2: bash if
#!/bin/bash
foo="qux"
bar="qux"
if [ "$foo" = "$bar" ]; then
echo "The strings are equal."
else
echo "The strings aren't equal."
fi