-
-
Notifications
You must be signed in to change notification settings - Fork 296
Commit template and $EDITOR
support
#758
-
A colleague of mine shared with me 2 easy possible improvements for cz commit
I want to share for feedback before submitting pull-requests.
git commit --template
Currently, committers have the choice between a fully prompted approach using cz commit
and no assistance except a pre-commit check.
He suggested that commitizen provide git commit --template <tpl>
support, so people used to commit from their editors would just have a commit template generated from the plugin.
I think this is a good idea and could take the form of a simple flag cz commit --template
which would basically wraps git commit --template <path/to/commitizen-generated.template>
with a commit template generated from the plugin prompts.
$EDITOR
support for multiline prompts
The discussion with him started by this. He asked me if cz commit
has some kind of support for opening multiline prompts into $EDITOR
.
I took a look at questionnary
and prompt-toolkit
which are used behind the scene, and there is
a open_in_editor
method allowing that.
I imagine we can add a flag --editor
to cz commit
to open multiline prompts in the editor.
What do you think ?
Beta Was this translation helpful? Give feedback.