How to test strings for lexicographic less than or equal in Bash? June 7, 2023 by Tarik Just negate the greater than test: if [[ ! "a" > "b" ]]