Be more verbose about curl errors

This commit is contained in:
Sandro Santilli 2013-07-04 11:04:12 +02:00
parent 6416af3f16
commit 8c51c97102

View File

@ -26,7 +26,11 @@ path="tiles/layergroup"
#port=8083
#path="database/cartodb_dev_user_1_db/layergroup"
res=`curl -skH Content-Type:application/json --data-binary "@${cfg}" ${proto}://${user}.${domain}:${port}/${path}`
cmd="curl -vskH Content-Type:application/json --data-binary @${cfg} ${proto}://${user}.${domain}:${port}/${path}"
res=`${cmd}`
if test $? -gt 0; then
echo "curl command failed: ${cmd}"
fi
if test x${verbose} = xyes; then
echo "${res}"