A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/conventional-changelog/commitlint/issues/2782 below:

ability to select multiple scopes since the rule scope-enum allows multiple values. · Issue #2782 · conventional-changelog/commitlint · GitHub

When using the rule scope-enum, @commitlint/prompt and @commitlint/cz-commitlint render the question as a list from which only one answer can be selected.
However, the rule scope-enum allows multiple values separated with a comma, back slash and/or forward slash

Expected Behavior

If the rule scope-enum is found in the config, the type of the question should be "checkbox" so multiple values can be selected.

Current Behavior

if the rule scope-enum is found in the config, the type of the question is "list" and only one value can be selected.

Affected packages Possible Solution

From what I understand "inquirer" is used to render the question. So if the rule scope-enum is found in the config, the type of the question should be "checkbox".

Steps to Reproduce (for bugs)
  1. Add scope-enum as a rule in the rules section of the commitlint config.
  2. Use @commitlint/prompt or @commitlint/cz-commitlint to render the question
Context

No being able to select multiple values for scope, forced me to duplicate the rule scope-enum and name it scope-choice so that the question is rendered as a question of type "text" instead of "list".

Your Environment Executable Version commitlint --version 13.2.0 git --version 2.31.0 node --version 14.17.0

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4