Files
settled-reach/tooling/tea-comment
T
jpmschweitzerandClaude Opus 4.6 99a7841bf2 feat(config): add tea-comment wrapper for Gitea PR comments
Single-command wrapper that handles temp file creation and cleanup
so tea comment works reliably with multi-line strings. Pre-approved
in settings.json, referenced in CLAUDE.md and pr-review skill.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-24 11:56:40 +01:00

19 lines
489 B
Bash
Executable File

#!/usr/bin/env bash
# Post a comment to a Gitea PR or issue.
# Usage: tea-comment <number> "comment body"
set -euo pipefail
if [[ $# -lt 2 ]]; then
echo "Usage: tea-comment <number> <comment>" >&2
exit 1
fi
NUMBER="$1"
BODY="$2"
HASH=$(echo -n "$BODY" | md5sum | cut -c1-8)
TMPFILE="/tmp/tea-comment-${NUMBER}-${HASH}.md"
trap 'rm -f "$TMPFILE"' EXIT
printf '%s' "$BODY" > "$TMPFILE"
tea comment --login schweitz --repo jpmschweitzer/settled-reach "$NUMBER" "$(cat "$TMPFILE")"