Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEAT] Add common messages to vscode's settings.json #338

Open
movahhedi opened this issue May 11, 2024 · 2 comments
Open

[FEAT] Add common messages to vscode's settings.json #338

movahhedi opened this issue May 11, 2024 · 2 comments
Assignees
Labels
question Further information is requested

Comments

@movahhedi
Copy link

Add a [configurable] prompt for choosing between common commit messages defined in vscode's settings.json (just like how we define scopes in it).

@movahhedi movahhedi added the question Further information is requested label May 11, 2024
@vivaxy
Copy link
Owner

vivaxy commented May 13, 2024

Hi, @movahhedi. Thanks for the good question.
In my situation, commit message representing the exact changes I've made to the repo. Commits with same commit message will be squashed into one.
I'm not familiar to your situation. Is it possible to provide more detailed use cases related to this feature?

@movahhedi
Copy link
Author

Some commit messages are commonly used, like when updating dependencies.
I have these scopes defined in my .vscode/settings.json:

{
	"conventionalCommits.scopes": ["client", "server", "deps"],
}

I suggest adding a commonMessages & showCommonMessages key:

{
	"conventionalCommits.scopes": ["client", "server", "deps"],
	"conventionalCommits.showCommonMessages": true,
	"conventionalCommits.commonMessages": [
		{
			"message": "style: lint & format",
			"desc": "Applied lints & formatted code"
		},
		{
			"message": "chore(deps): update dependencies",
			"desc": "Updated dependencies"
		},
		{
			"message": "chore: update yarn",
			"desc": "Updated Yarn version"
		},
	],
}

And if showCommonMessages was true, adding a dialog at the start of the commit questions, to choose from the defined messages in commonMessages.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants