Skip to content

Commit

Permalink
refactor(shortcuts): move check for shortcut config setting to apply …
Browse files Browse the repository at this point in the history
…to any list select
  • Loading branch information
zevisert authored and Lee-W committed Aug 13, 2021
1 parent 6820271 commit e333537
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 2 additions & 0 deletions commitizen/commands/commit.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ def prompt_commit_questions(self) -> str:
# Prompt user for the commit message
cz = self.cz
questions = cz.questions()
for question in filter(lambda q: q['type'] == 'list', questions):
question["use_shortcuts"] = self.config.settings["use_shortcuts"]
try:
answers = questionary.prompt(questions, style=cz.style)
except ValueError as err:
Expand Down
1 change: 0 additions & 1 deletion commitizen/cz/conventional_commits/conventional_commits.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,6 @@ def questions(self) -> List[Dict[str, Any]]:
"type": "list",
"name": "prefix",
"message": "Select the type of change you are committing",
"use_shortcuts": self.config.settings["use_shortcuts"],
"choices": [
{
"value": "fix",
Expand Down

0 comments on commit e333537

Please sign in to comment.