git_revert
Undo an already committed bad change by adding a new commit with the opposite changes, preserving history. Fails on merge conflicts; use git_restore for uncommitted file edits.
Instructions
Undo one earlier commit by adding a new commit with the opposite changes; history is kept, and the files in the mirror change accordingly. Use it to roll back a bad change that is already committed. Fails on a merge conflict. To undo uncommitted edits to one file, use git_restore instead.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"ref": "<ref>"
},
"name": "git_revert"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | Yes | Commit to undo: a hash from git_log, or e.g. "HEAD" for the latest. | |
| place | No | Target place (PlaceId or project name) whose mirror repo to use. Defaults to the bound/sole connected place. |