feat: add PR review and edit tools to CLI and MCP server
This commit is contained in:
@@ -41,9 +41,11 @@ Any MCP-compatible agent (Antigravity, Claude Code, etc.) can call these tools n
|
||||
|------|-------------|
|
||||
| `gitea_create_issue` | Create an issue with title, body, remote |
|
||||
| `gitea_create_pr` | Open a pull request with title, head, base |
|
||||
| `gitea_edit_pr` | Edit details of an existing pull request |
|
||||
| `gitea_list_prs` | List pull requests with state/remote |
|
||||
| `gitea_view_pr` | Get full details of a single pull request |
|
||||
| `gitea_merge_pr` | Merge a pull request (merge, squash, or rebase) |
|
||||
| `gitea_review_pr` | Submit a review on a pull request and optionally merge it |
|
||||
| `gitea_delete_branch` | Delete a remote branch |
|
||||
| `gitea_close_issue` | Close an issue by number |
|
||||
| `gitea_list_issues` | List issues with state/label filters |
|
||||
@@ -52,6 +54,8 @@ Any MCP-compatible agent (Antigravity, Claude Code, etc.) can call these tools n
|
||||
| `gitea_list_labels` | List all available labels in a repository |
|
||||
| `gitea_create_label` | Create a new label with custom color |
|
||||
| `gitea_set_issue_labels` | Replace all labels on an issue |
|
||||
| `gitea_get_file` | Retrieve file content and SHA metadata |
|
||||
| `gitea_commit_files` | Commit changes to multiple files atomically |
|
||||
| `gitea_mirror_refs` | Mirror branches + tags between instances |
|
||||
|
||||
### Setup
|
||||
@@ -139,6 +143,8 @@ The MCP tools can also be used as standalone CLI scripts:
|
||||
|---------------------|--------------------------------------------------------------------|
|
||||
| `create_issue.py` | Create an issue (`--remote`, `--title`, `--body`, `--body-file`) |
|
||||
| `create_pr.py` | Open a Pull Request (`--remote`, `--title`, `--head`, `--base`) |
|
||||
| `edit_pr.py` | Edit a Pull Request (`--title`, `--body`, `--body-file`, etc.) |
|
||||
| `review_pr.py` | Review and sign-off on a pull request (with optional merge) |
|
||||
| `close_issue.py` | Close a specific issue |
|
||||
| `mark_issue.py` | Claim/release an issue via `status:in-progress` label |
|
||||
| `manage_labels.py` | Create label set and apply label mappings (`--dry` to preview) |
|
||||
@@ -156,6 +162,12 @@ The MCP tools can also be used as standalone CLI scripts:
|
||||
# Create a PR
|
||||
./create_pr.py --title "feat: add validation" --head feat/validation --body "Closes #12"
|
||||
|
||||
# Edit a PR's description or title
|
||||
./edit_pr.py 155 --body "Updated description wording"
|
||||
|
||||
# Review and approve a PR, then automatically merge it
|
||||
./review_pr.py --pr-number 12 --event APPROVE --body "Approved" --merge
|
||||
|
||||
# Close issue #5
|
||||
./close_issue.py 5
|
||||
|
||||
@@ -181,6 +193,8 @@ gitea_auth.py ← shared auth & API helpers (get_credentials, api_request)
|
||||
mcp_server.py ← MCP server (FastMCP, stdio transport)
|
||||
create_issue.py ← CLI: create issues
|
||||
create_pr.py ← CLI: create PRs
|
||||
edit_pr.py ← CLI: edit PRs
|
||||
review_pr.py ← CLI: review PRs
|
||||
manage_labels.py ← CLI: label management
|
||||
close_issue.py ← CLI: close issues
|
||||
mark_issue.py ← CLI: claim/release issues
|
||||
|
||||
Reference in New Issue
Block a user