Skip to content

Could replace more non-word characters #165

@dustinlagoy

Description

@dustinlagoy

I have an argparse script which accepts subcommands with names like:

my/first/subcommand
my/second/subcommand

which end up causing invalid completion scripts similar to #20.

It would be trivial to add / to the list of characters replaced in wordify(), or even change the character set to \W to replace any non-word character. Are either of these options preferable? (both work when tested with my script)

I'm happy to put together a one-line pull request if you think this is worthwhile.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions