Fix sort -V to work on OS X

This commit is contained in:
JustArchi 2017-04-06 00:23:48 +02:00
parent 18800b0436
commit 68d49c8ec1

View file

@ -67,7 +67,7 @@ VERSION_LESS_THAN() {
}
VERSION_LESS_EQUAL_THAN() {
[ "$1" = "$(echo -e "$1\n$2" | sort -V | head -n 1)" ]
[ "$1" = "$(echo -e "$1\n$2" | sort -t . -k 1,1n -k 2,2n -k 3,3n -k 4,4n | head -n 1)" ]
}
# Main