Skip to content
Permalink
Browse files

Make Grep case insensitive in download script

Github made the location header lowercase, so our get.sh script was
failing. This makes the grep case insensitive.

Tested by running the script to make sure it failed, then making the
grep into a `grep -i` and running again, this time it worked.

Signed-off-by: Alistair Hey <alistair@heyal.co.uk>
  • Loading branch information
Waterdrips authored and alexellis committed Feb 28, 2020
1 parent 6645e9b commit 6a698ed0ef7e720ef25460fb3bf2f37fa044944d
Showing with 1 addition and 1 deletion.
  1. +1 −1 get.sh
2 get.sh
@@ -16,7 +16,7 @@ export BINLOCATION="/usr/local/bin"
# Content common across repos #
###############################

version=$(curl -sI https://github.com/$OWNER/$REPO/releases/latest | grep Location | awk -F"/" '{ printf "%s", $NF }' | tr -d '\r')
version=$(curl -sI https://github.com/$OWNER/$REPO/releases/latest | grep -i location | awk -F"/" '{ printf "%s", $NF }' | tr -d '\r')
if [ ! $version ]; then
echo "Failed while attempting to install $REPO. Please manually install:"
echo ""

0 comments on commit 6a698ed

Please sign in to comment.
You can’t perform that action at this time.