restore_from_history
Restore a file to a specific version from its local history by specifying the file path and history entry index. Optionally create a backup of the current file before restoration.
Instructions
Restore a file to a specific point in its local history
Input Schema
Name | Required | Description | Default |
---|---|---|---|
createBackup | No | Whether to create a backup of the current file before restoring | |
entryIndex | Yes | The index of the history entry to restore (0 = most recent) | |
filePath | Yes | The absolute path to the file to restore (e.g., "/Users/user/project/biome.json"). |
Input Schema (JSON Schema)
{
"additionalProperties": false,
"properties": {
"createBackup": {
"default": true,
"description": "Whether to create a backup of the current file before restoring",
"type": "boolean"
},
"entryIndex": {
"description": "The index of the history entry to restore (0 = most recent)",
"type": "number"
},
"filePath": {
"description": "The absolute path to the file to restore (e.g., \"/Users/user/project/biome.json\").",
"type": "string"
}
},
"required": [
"filePath",
"entryIndex"
],
"type": "object"
}