How eugenekozhun/committle works
Committle is a JetBrains IDE plugin for composing consistent commit messages from configurable templates. The documented workflow is to invoke the apply-pattern action, which turns a template into a commit message with variables, whitespace rules, and a caret position. Settings persist per project; the template language also has parsing, highlighting, and completion support. The graph includes the principal services and documented capabilities, but action and UI implementation excerpts were not provided, so their internal call wiring is not asserted.
Main entry points: CommitMessageFormatterDefaultImpl.kt Message formatter · GenerateCommitMessageAction.kt Apply pattern · CMTParserDefinition.kt Parser definition · CMTSettingsPage.kt Settings page
Components 21
Message workflow
- Apply pattern
src/main/kotlin/com/kozhun/commitmessagetemplate/action/GenerateCommitMessageAction.kt - Commit message
Template language
- Template file
src/main/kotlin/com/kozhun/commitmessagetemplate/language/psi/CMTFile.kt - Parser definition
src/main/kotlin/com/kozhun/commitmessagetemplate/language/parser/CMTParserDefinition.kt - Lexer adapter
src/main/kotlin/com/kozhun/commitmessagetemplate/language/lexer/CMTLexerAdapter.kt - Template parser
src/main/gen/com/kozhun/commitmessagetemplate/language/parser/CMTParser.java - Variable completion
src/main/kotlin/com/kozhun/commitmessagetemplate/language/completion/CMTCompletionContributor.kt - Syntax highlighting
src/main/kotlin/com/kozhun/commitmessagetemplate/language/highlighter/CMTSyntaxHighlighter.kt
Settings
- Settings page
src/main/kotlin/com/kozhun/commitmessagetemplate/ui/page/CMTSettingsPage.kt - Pattern editor
src/main/kotlin/com/kozhun/commitmessagetemplate/ui/components/PatternEditorBuilder.kt - Project settings
src/main/kotlin/com/kozhun/commitmessagetemplate/storage/SettingsStorage.kt - Settings state
src/main/kotlin/com/kozhun/commitmessagetemplate/storage/SettingsState.kt
Message services
- Current branch
src/main/kotlin/com/kozhun/commitmessagetemplate/service/git/branch/impl/GitBranchServiceImpl.kt - Variable replacers
src/main/kotlin/com/kozhun/commitmessagetemplate/service/replacer/impl/BranchTaskIdReplacer.kt - File scope
src/main/kotlin/com/kozhun/commitmessagetemplate/service/replacer/impl/FilePathScopeReplacer.kt - Branch type
src/main/kotlin/com/kozhun/commitmessagetemplate/service/replacer/impl/BranchTypeReplacer.kt - Message formatter
src/main/kotlin/com/kozhun/commitmessagetemplate/service/formatter/impl/CommitMessageFormatterDefaultImpl.kt - Whitespace rules
src/main/kotlin/com/kozhun/commitmessagetemplate/service/whitespace/impl/WhitespaceServiceDefaultImpl.kt - Caret placement
src/main/kotlin/com/kozhun/commitmessagetemplate/service/caret/impl/CaretServiceDefaultImpl.kt
Other components
- IDE user
- IDE Git data
Connections 15
- IDE user → Apply pattern: invokes
- Parser definition → Lexer adapter: creates lexer
- Parser definition → Template parser: creates parser
- Settings page → Pattern editor: uses editor
- Settings page → Project settings: configures
- Project settings → Settings state: stores
- Current branch → IDE Git data: reads branch
- Apply pattern → Commit message: applies pattern
- Apply pattern → Message formatter: formats message
- Message formatter → Whitespace rules: normalizes whitespace
- Message formatter → Caret placement: sets caret position
- Message formatter → Variable replacers: resolves variables
- Message formatter → File scope: resolves scope
- Message formatter → Branch type: resolves type
- Variable replacers → Current branch: reads branch