ACT-agentcommandotower / scripts /ensure-agent-labels.sh
smlflg's picture
Initial public upload from Projekte/ACT-agentcommandotower
a2be137 verified
Raw History Blame Contribute Delete
1.03 kB
#!/usr/bin/env bash
set -euo pipefail
if ! command -v gh >/dev/null 2>&1; then
echo "gh CLI is required to create labels." >&2
exit 1
fi
if ! gh repo view >/dev/null 2>&1; then
echo "Run this script inside a GitHub repository with gh authenticated." >&2
exit 1
fi
labels=(
"agent:read-only|0e8a16|Read-only audit or analysis work"
"agent:test-generation|5319e7|Tests for existing behavior"
"agent:small-fix|1d76db|Small scoped fix"
"agent:review|fbca04|Review or adversarial analysis"
"agent:docs|0075ca|Documentation reality sync"
"agent:decision|d93f0b|Decision record or consolidation analysis"
"agent:needs-human|b60205|Human input or approval required"
"agent:safe|0e8a16|Low-risk agent work"
"agent:risky|d93f0b|Higher-risk work requiring scrutiny"
"agent:blocked|000000|Blocked work"
)
for spec in "${labels[@]}"; do
IFS="|" read -r name color description <<<"$spec"
gh label create "$name" --color "$color" --description "$description" --force
done
echo "Agent labels are present."