Skip to content

Commit

Permalink
use awk instead of gawk
Browse files Browse the repository at this point in the history
  • Loading branch information
nyurik committed Feb 24, 2020
1 parent 2f60ca0 commit 036a96f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion quickstart.sh
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ docker --version
docker-compose --version

# based on: http://stackoverflow.com/questions/16989598/bash-comparing-version-numbers
function version { echo "$@" | tr -cs '0-9.' '.' | gawk -F. '{ printf("%03d%03d%03d\n", $1,$2,$3); }'; }
function version { echo "$@" | tr -cs '0-9.' '.' | awk -F. '{ printf("%03d%03d%03d\n", $1,$2,$3); }'; }

COMPOSE_VER=$(docker-compose version --short)
if [ "$(version "$COMPOSE_VER")" -lt "$(version "$MIN_COMPOSE_VER")" ]; then
Expand Down

0 comments on commit 036a96f

Please sign in to comment.