Skip to content

bash completion replaces underscores with dashes #1235

@noqqe

Description

@noqqe

Hi,

since I've upgraded to click 7.0 the bash completion replaces underscores (_) in command names with dashes (-)

@click.command(short_help="Delete a group")
@click.option("groupname", '-g', '--group', type=str, required=True)
@click.option("--yes", is_flag=True, default=False)
@click.pass_context
def delete_group(ctx, yes, groupname):
    """
    Deletes a group identified by its short ID

the help message it looks like this:

Options:
  --version                   Show the version and exit.
  -e, --env [prod|stage|dev]  Choose environment to execute commands
  -h, --help                  Show this message and exit.

Commands:
  create_project          Creates a new project
  delete_group            Delete a group
  [...]

Gif example here:
feb-19-2019 10-47-51

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions