mirror of
https://github.com/fluencelabs/fluid
synced 2025-06-18 07:41:20 +00:00
Handle absence of jq & base64
This commit is contained in:
@ -29,7 +29,7 @@ JSON
|
||||
echo -e "Sending request... $JSON"
|
||||
|
||||
# Send json as a request, and receive result
|
||||
RESPONSE=$(curl -s 'http://localhost:30000/apps/1/tx' --data $'sessionId/0\n'"$JSON" --compressed | jq -r .result.data | base64 -D)
|
||||
RESPONSE=$(curl -s 'http://localhost:30000/apps/1/tx' --data $'sessionId/0\n'"$JSON" --compressed | jq -r .result.data | base64 --decode)
|
||||
|
||||
# Parse json or print response as is
|
||||
echo "$RESPONSE" | jq . 2>/dev/null || echo "$RESPONSE"
|
||||
|
Reference in New Issue
Block a user