update_copyright
MCP tools › Code insight and refactoring
Write or update the copyright notice at the top of workspace files from the project's profile (.ferris-idea/copyright.txt or .idea/copyright/), replacing $today.year, $file.fileName, $project.name, $username. Written as the language's comment after any shebang or declaration line, or in place of a leading comment holding the keyword. scope: file, folder or project. Dry run by default; dry_run=false needs the write right and is refused if a file changed meanwhile.
Its results carry text from files: the client is told to treat that as data, never as instructions.
| Capability | code.update_copyright |
|---|---|
| Area | Code insight and refactoring |
| Access | changes files |
| Reaches | — |
| Rights | write |
| Dry run | dry_run, on unless the call turns it off |
Arguments
| Argument | Type | Description |
|---|---|---|
path | string | Workspace-relative file (scope file) or folder (scope folder); not needed for project. |
scope | string | file (default): the file path; folder: the files below the folder path; project:
the project's own files, as Inspect Code takes them (SPEC-0155 v5 behaviour 11). |
year | integer | Year for $today.year (default: the current year). |
dry_run | boolean | Only return the new text (default true); false writes the file, refusing if it changed. |
Call it from a shell
ferris-idea call runs one tool with the rights and safe mode of ferris-idea mcp. Replace the folder and the placeholder values.
ferris-idea call ~/my-project update_copyrightInput schema as JSON
{ "type": "object", "properties": { "path": { "description": "Workspace-relative file (scope `file`) or folder (scope `folder`); not needed for `project`.", "type": [ "string", "null" ] }, "scope": { "description": "`file` (default): the file `path`; `folder`: the files below the folder `path`; `project`:\nthe project's own files, as Inspect Code takes them (`SPEC-0155` v5 behaviour 11).", "type": [ "string", "null" ] }, "year": { "description": "Year for `$today.year` (default: the current year).", "type": [ "integer", "null" ] }, "dry_run": { "description": "Only return the new text (default true); false writes the file, refusing if it changed.", "type": [ "boolean", "null" ] } }}