Skip to content

fish_update_completions includes non-argument text from descriptions #4313

@mqudsi

Description

@mqudsi

Running fish_update_completions results in these invalid completions being added to the s3cmd autogenerated completions file:

complete -c s3cmd -l '(r)exclude(-from' --description '.'
complete -c s3cmd -l 'guess-mime-type.' --description '.'

The first is caused by this line in the man file:

   --include=GLOB
          Filenames  and  paths  matching  GLOB  will  be  included  even  if  previously  excluded  by   one   of
          --(r)exclude(-from) patterns

Is it ok to exclude ( and ) from the search regex? I don't think I've ever seen a unix command that has a parentheses in an argument in all my years, no matter how misguided the developer (though I'm sure somewhere out there such a command does exist).

The second is caused by this line in the man file:

   -m MIME/TYPE, --mime-type=MIME/TYPE
          Force MIME-type. Override both --default-mime-type and --guess-mime-type.

Same question: can we exclude punctuation from the argument search regex? If not, we can surely exclude trailing punctuation, right?

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions