if larger than bash code example
Example 1: bash if greater than
if (( a > b )); then
...
fi
#Use above example or below one:
if [ "$a" -gt "$b" ]; then
...
fi
Example 2: bash if larger than
# In bash, you should do your check in arithmetic context:
if (( a > b )); then
...
fi
# For POSIX shells that don't support (()), you can use -lt and -gt.
if [ "$a" -gt "$b" ]; then
...
fi