[Feature]: Allow fully custom prompts
Description
Why: The prompt modification options will never replicate the simplicity and customization of simply writing the prompt yourself. Users should have the choice. Allowing them to print out the prompt that would be used will give a starting point.
Suggested Solution
- Add config option OCO_CUSTOM_PROMPT: it will ignore all other prompt-manipulating options and set the prompt to exactly what the user specifies.
- Add an oco --show-prompt flag: prints to stdout the prompt that would be used (don't do anything)
Alternatives
No response
Additional Context
No response
Killer feature! Classic use case is trying to infer and enforce (JIRA/Linear/GitHub) ticket references in each commit.
agree, custom prompt would be lit, @Danjoe4 @codekiln do you gues want to contribute with a PR?
@di-sukharev Glad you like the idea. Yes, I will submit a PR for this within the next few days.
The reason I sought out opencommit was that in 2025, many of the agentic coding tools didn't always follow detailed commit message style guidelines (e.g. conventional commit first line, then empty line, then commit message body, then empty line, then JIRA ticket number and ticket human name).
In my opinion, this feature could potentially be more powerful if one could supply a custom system prompt and also the intended rough description of the commit's context, and have opencommit rephrase that in a way that obeyed the prompt. That way an agentic coding tool could 1.) write a summary of what was accomplished, 2.) pass it to opencommit for commit along with the project's conventions to get the most accurate commit message.