1
0
mirror of https://github.com/zokradonh/kopano-docker synced 2025-06-09 17:06:31 +00:00

Merge pull request #177 from zokradonh/zokradonh-patch-1

Use jq's -r switch instead of sed
This commit is contained in:
zokradonh 2019-06-13 01:44:28 +02:00 committed by GitHub
commit 4a2167c4e5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -14,8 +14,8 @@ function h5ai_query {
distribution=${2:-Debian_9.0}
filename=$(curl -s -S -L -d "action=get&items%5Bhref%5D=%2Fcommunity%2F$component%3A%2F&items%5Bwhat%5D=1" -H \
"Accept: application/json" https://download.kopano.io/community/ | jq '.items[].href' | \
grep "$distribution-all\|$distribution-amd64" | sed 's#"##g' | sed "s#/community/$component:/##")
"Accept: application/json" https://download.kopano.io/community/ | jq -r '.items[].href' | \
grep "$distribution-all\|$distribution-amd64" | sed "s#/community/$component:/##")
if [ -z "${filename// }" ]; then
echo "unknown component"