5.6 KiB
5.6 KiB
allowed-tools, argument-hint, description
| allowed-tools | argument-hint | description |
|---|---|---|
| Glob, Grep, Read, Write, Edit, LS | [rubric-path] | Configure rubric settings for the current project |
Rule
The <execute>ARGUMENTS</execute> will execute the main procedure.
Role
You are a assistant to help update config.
Config Schema
The configuration file claudekit.json has the following structure:
{
"rubric": {
"enforce": true, // Omitted otherwise user ask for config change
"reviewMessage": "Make self-review with {references}", // Omitted otherwise user ask for config change, the {references} placeholder must be included
"rules": [
{
"name": "JavaScript Files", // Optional descriptive name for the rule
"pattern": ".*\\.js$",
"path": "path/to/rubric/document.md"
}
]
}
}
Pattern
Prevent to use ^ to match the start of the edited file path, as the path may be relative or absolute.
By default, prefer to use .*\\.js$ to match any path ending with .js.
- The relative and absolute path matching should be supported.
- Use
$to ensure the file extension is at the end of the path.
Definition
Read existing claudekit.json configuration file 1. Check if [.claude/]claudekit[.local].json file exists 2. Read and parse the JSON content of the file Parsed JSON object Empty JSON object Update claudekit.json with new rubric rule Existing configuration object Rubric name File pattern to apply rubric in RegExp Path to the rubric document 1. Call to get current configuration 2. Update or add the rubric configuration under "rubric.rules" key with provided {name}, {pattern}, and {path} 3. Write the updated configuration back to [.claude/]claudekit[.local].json file Configuration update status Update claudekit.json with new enforce setting Existing configuration object Boolean to enable or disable enforcement 1. Call to get current configuration 2. Update or add the "rubric.enforce" key with provided {enforce} value <> 3. Write the updated configuration back to [.claude/]claudekit[.local].json file Configuration update status Update claudekit.json with new review message Existing configuration object Review message template 1. Ensure references placeholder {references} is included in the message 2. Call to get current configuration 3. Update or add the "rubric.reviewMessage" key with provided {message} 4. Write the updated configuration back to [.claude/]claudekit[.local].json file Configuration update status Update claudekit.json to modify rubric config Document path define the rubric 1. Confirm with user to update rules or change config, e.g. enforce or reviewMessage 2. Set {action} to user input 3. Ask user to provide enforce value (true/false) use ask question tool 4. Set {enforce} to user input 5. {config} {enforce} to update the config file Configuration update status 3. Ask user to provide the review message template 4. Set {message} to user input 5. {config} {message} to update the config file Configuration update status 3. Ask user to provide the path to the rubric document 4. Set {path} to user input 5. Review the provided {path} to understand the rubric apply to the project 6. Set {name} and {pattern} based on the rubric document 7. Use ask question tool to confirm with user if the detected {name} and {pattern} are correct 8. Ask user to provide the correct {name} and {pattern} 9. Set {name} and {pattern} to user input 10. {config} {name} {pattern} {path} to update the config file Configuration update statusTask
$ARGUMENTS