fix: set Gitea token scopes for PaC

This commit is contained in:
Codex
2026-07-05 10:58:18 +00:00
parent d32575fff2
commit 252525e29c
@@ -72,7 +72,7 @@ gitea_api() {
ensure_token() {
name="unidesk-pac-$(date +%Y%m%d%H%M%S)"
body=$(printf '{"name":"%s"}' "$name")
body=$(printf '{"name":"%s","scopes":["all"]}' "$name")
out=$(gitea_api POST "users/$UNIDESK_PAC_GITEA_API_USERNAME/tokens" "$body")
printf '%s' "$out" | sed -n 's/.*"sha1"[[:space:]]*:[[:space:]]*"\([^"]*\)".*/\1/p'
}