12 lines
283 B
Bash
12 lines
283 B
Bash
#!/bin/bash
|
|
|
|
PASTE_ID="$1"
|
|
HOST="${2:-http://100.87.87.103:8184}"
|
|
|
|
if [ -z "$PASTE_ID" ]; then
|
|
echo "Verwendung: $0 <paste-id> [host]"
|
|
exit 1
|
|
fi
|
|
|
|
curl -s "$HOST/api/v1/paste/$PASTE_ID" | \
|
|
python3 -c 'import json,sys; print(json.loads(sys.stdin.read())["files"][0]["content"])' |