port search --maintainer[s]

Jan Stary hans at stare.cz
Fri Mar 31 06:37:19 UTC 2017


On Mar 31 02:07:15, raimue at macports.org wrote:
> On 2017-03-30 23:44, Jan Stary wrote:
> > On Mar 30 21:06:59, raimue at macports.org wrote:
> >> On 03/30/2017 06:18 PM, Jan Stary wrote:
> >>> This is 2.4.99 from git running on 10.6.8.
> >>> The 'port search' recognizes '--maintainer' and '--maintainers',
> >>> but the guide says '--maintainer' and '--maintainer'
> >>> while port-search.1 only says '--maintainer'.
> >>> Attached please find a diff for each.
> >>
> >> Note that all long options can be shortened as long as they are unique, so you
> >> could even use 'port search --maint foobar'.
> > 
> > $ port search --maint mandoc
> > Error: "port search --maint" is ambiguous: 
> >   port search --maintainer
> >   port search --maintainers
> 
> Sorry, that's what happens when I do not test my examples...
> 
> >> Maybe we want to simplify the code
> >> and leave out the explicit singular forms (although we cannot do that for
> >> "categories")?
> > 
> > I don't understand why there is more then one at all.
> 
> In natural language you would use either singular or plural, depending
> on the way it is used in a query. The port command just tries to be as
> convenient as possible.

But it's the other way now: if e.g. '--maintainers' was be the only one,
with unique shortenings working, you would also have '--maintaniner'
and '--maintain'. With both --maintainer and --maintainers recognized
as separated --options, it has to be one of the two, literaly,
because everything else is ambiquous. So recognizign only --maintainers
would actually be more convenient.

I suggest we only keep --maintainers and --variants.

With --categories, we don't have --category as a shortening,
but having --category makes --cat ambiguous, as above ...

	Jan



More information about the macports-dev mailing list