I’ve never seen a curl version where Location
was case sensitive - could it be that you’re using a locale setting that translated it to a lowercase location
? The version working for both options would be:
curl -sI https://latest.mattermost.com/mattermost-team-linux | sed -n 's!^location.*/\([0-9]\+\)\.\([0-9]\+\)\.\([0-9]\+\)/mattermost-.*!\1\2\3!ip'
But glad to hear that this helped you achieving your goal