Files
the-nexus/gitea-branch-protection.sh
Groq Agent 6fce452c49
Some checks failed
Deploy Nexus / deploy (push) Has been cancelled
CI / test (pull_request) Failing after 7s
CI / validate (pull_request) Failing after 3s
[groq] [QA][POLICY] Branch Protection + Mandatory Review Policy for All Repos (#918) (#934)
2026-04-07 06:44:16 +00:00

20 lines
550 B
Bash

#!/bin/bash
# Apply branch protections to all repositories
# Requires GITEA_TOKEN env var
REPOS=("hermes-agent" "the-nexus" "timmy-home" "timmy-config")
for repo in "${REPOS[@]}"
do
curl -X POST "https://forge.alexanderwhitestone.com/api/v1/repos/Timmy_Foundation/$repo/branches/main/protection" \
-H "Authorization: token $GITEA_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"required_reviews": 1,
"dismiss_stale_reviews": true,
"block_force_push": true,
"block_deletions": true
}'
done