X-Git-Url: https://git.sven.stormbind.net/?a=blobdiff_plain;f=artifactory%2Fterraform-dl.sh;h=f62be23d0eba5416b392d1e3f06c8766465678f4;hb=HEAD;hp=19e5e3465aa5a8c79ad072a90bb2947e6700d8a4;hpb=d3989b9a70f7a98039aaa94c1e07e65a2414e415;p=sven%2Fscripts.git diff --git a/artifactory/terraform-dl.sh b/artifactory/terraform-dl.sh index 19e5e34..f62be23 100755 --- a/artifactory/terraform-dl.sh +++ b/artifactory/terraform-dl.sh @@ -1,7 +1,7 @@ #!/bin/sh LATEST_LINK="https://github.com/hashicorp/terraform/releases/latest" -VERSION="$(curl -si ${LATEST_LINK} | grep Location | grep -Po '[0-9]\.[0-9]{1,2}\.[0-9]+')" +VERSION="$(curl -sI ${LATEST_LINK} | grep -i '^Location' | grep -Po '[0-9]\.[0-9]{1,2}\.[0-9]+')" BASE_DOWNLOAD="https://releases.hashicorp.com/terraform/${VERSION}/" ARCH="amd64" OS="linux"