File history
file_historyLists commits that changed a single file, newest first, following renames and showing paths and line changes so you can see how it evolved and who reworked it.
Instructions
List the commits on HEAD that changed a single file, newest first, following the file across renames. Each commit includes the path it had then and lines added/removed. Useful for "how did this file evolve?" and "who reworked it, and when?".
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": {
"path": "<path>"
},
"name": "file_history"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | Repository-relative path of a single file, as named at HEAD. | |
| repo | No | Repo name or path; defaults to the first configured repo. | |
| limit | No | Maximum number of results. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | The requested path, as it is named at HEAD. | |
| repo | Yes | Name of the repository that was queried. | |
| commits | Yes | ||
| renamed | Yes | True if the file had a different path in a listed commit. | |
| truncated | Yes | ||
| commitCount | Yes |