di-sukharev / opencommit

Generate conventional git commit messages with AI in 1 second 🤯🔫
https://www.npmjs.com/package/opencommit
MIT License
5.98k stars 318 forks source link

[Feature]: Branch Naming Integration for Enhanced Commit Messages in OpenCommit #270

Open JonasWijne opened 10 months ago

JonasWijne commented 10 months ago

Description

integrate branch naming conventions into the commit message generation process. Users frequently use branch names like feature/{ticketnumber}-normal-branch-name in their version control workflows. However, they have to manually include the ticket number in their commit messages, which can be tedious and error-prone.

Suggested Solution

Implement a new feature that allows for automatic extraction of ticket numbers from branch names. When a branch is named in a specific format (e.g., feature/{ticketnumber}-normal-branch-name), OpenCommit should detect the ticket number and prepend or append it to the commit message, formatted as ticket: {ticketnumber}. This functionality would significantly streamline the commit process, reduce manual errors, and improve efficiency. The implementation should be flexible to accommodate different branch naming conventions and should be easily configurable through the existing settings. Additionally, offering an option to toggle this feature on or off per repository basis would provide users with greater control and customization.

Alternatives

No response

Additional Context

No response

github-actions[bot] commented 9 months ago

Stale issue message

di-sukharev commented 7 months ago

reopening, will take a look at this

seanmccabe commented 3 months ago

This would be super handy