Files
forgebot/internal/provider/gitea/comments.go
T
unkinben 49d514c050 Initial scaffold: API service, K8s operator, and CRDs
Forgebot is a K8s operator + API service for dispatching AI agent
jobs from git forge commands. Includes:

- CRDs: AgentPool, AgentTask, ProviderQueue, RepositoryBinding
- API server with webhook handler, task queue, and comment proxy
- Operator controllers for task scheduling and job management
- Gitea provider with webhook parsing and signature verification
- PostgreSQL database with auto-migration
- Woodpecker CI pipelines and multi-stage Dockerfiles
2026-06-08 22:49:18 +10:00

18 lines
460 B
Go

package gitea
import (
sdk "code.gitea.io/sdk/gitea"
)
func (c *Client) PostComment(owner, repo string, issueOrPR int, body string) error {
_, _, err := c.api.CreateIssueComment(owner, repo, int64(issueOrPR), sdk.CreateIssueCommentOption{
Body: body,
})
return err
}
func (c *Client) AddReaction(owner, repo string, commentID int64, reaction string) error {
_, _, err := c.api.PostIssueCommentReaction(owner, repo, commentID, reaction)
return err
}