Git-AIC supports editable system prompts.
Edit the global prompt in your editor:
git aic prompt editSet it directly from text:
git aic prompt edit --text "Write concise conventional commits with a short body when needed."Load it from a file:
git aic prompt edit --file ./prompt.txtReset it to the built-in default:
git aic prompt resetLocal prompts override the global prompt for the current repository only. They are private to your clone because Git-AIC stores them in local Git config.
Edit the local prompt:
git aic prompt edit --localSet it from text:
git aic prompt edit --local --text "Use a short subject and a clear explanatory body."Load it from a file:
git aic prompt edit --local --file ./commit-prompt.txtReset the local prompt:
git aic prompt reset --localShared repository prompts are saved in git-aic.config.json.
Commit this file when a team wants the same prompt rules across the repository.
Shared repository prompts take priority over private local and global prompts.
Create a shared repository config:
git aic initEdit the shared repository prompt:
git aic prompt edit --repoSet it from text:
git aic prompt edit --repo --text "Use Conventional Commits format: <type>(<scope>): <description>. Keep the subject under 72 characters. Use scopes that match the changed package, module, or feature area. Write clear imperative summaries without trailing punctuation. Include a short body with bullet points only when the change is complex. Do not include explanations outside the commit message."Load it from a file:
git aic prompt edit --repo --file ./commit-prompt.txtReset the shared repository prompt:
git aic prompt reset --repoWhen Git-AIC builds the prompt for the model, it resolves in this order:
- shared repository prompt from
git-aic.config.json - private local prompt from Git config
- global prompt from Git-AIC config
- built-in default prompt
Global prompt data is stored in Git-AIC's own config.
Local prompt data is stored in repository Git config under:
[aic]
prompt = ...Git-AIC writes this through git config --local.
Shared repository prompt data is stored in:
git-aic.config.json
The file uses the prompt field:
{
"prompt": "Use Conventional Commits format: <type>(<scope>): <description>. Keep the subject under 72 characters. Use scopes that match the changed package, module, or feature area. Write clear imperative summaries without trailing punctuation. Include a short body with bullet points only when the change is complex. Do not include explanations outside the commit message."
}When Git-AIC opens an editor, it resolves the editor in this order:
VISUALEDITOReditor