di-sukharev / di-sukharev/opencommit
[Feature Request] Pull request title based on files diff
Open
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 7.5k
- Forks
- 445
- Avg merge
- 18m
- Merged PRs (30d)
- 2
Description
Context
I know that the purpose of the CLI is to help create commit messages, but it would be nice to have the option to suggest pull request titles based on differences in modified files.
In this example, the user should copy the suggested title, I don't think there's a simple way to automate this.
Example
➜ opencommit --pull-request
┌ open-commit
│
◇ 1 staged files:
example-repo/test.js
│
◇ 📝 Commit message generated
│
└ Commit message:
——————————————————
* feat(test.js): add test file
——————————————————
│
◇ Confirm the commit message
│ Yes
│
└ ✔ successfully committed
│
└ [main] * feat(test.js): add test file
1 files changed, 1 insertions(+), 0 deletions(-)
│
◇ 📖 Pull Request title generated
│
└ Pull Request title:
——————————————————
* feat: Create sample test file
——————————————————
│
◇ Do you want to run `git push`?
│ Yes
│
◇ ✔ successfully pushed all commits
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the CLI flow for the --pull-request option and the existing commit-message generation flow. Implement the requested pull-request title suggestion from the modified-file diff, then verify that the example flow displays the title before the push prompt.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- git, javascript
- Domain
- cli, developer-experience
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100