[pacman-dev] Why not using the bash getopts buildin? Was: Removing deltas from repos

Allan McRae allan at archlinux.org
Thu Sep 17 04:58:07 EDT 2009


Dieter Plaetinck wrote:
> On Wed, 16 Sep 2009 18:10:24 -0500
> Dan McGee <dpmcgee at gmail.com> wrote:
>
>   
>> On Wed, Sep 16, 2009 at 6:08 PM, Allan McRae <allan at archlinux.org>
>> wrote:
>>     
>>> Dieter Plaetinck wrote:
>>>       
>>>> My 2 cents: portability is important, and code conciseness is more
>>>> important then having a fancy interface with many possibilities.
>>>> Isn't it just redundant/bloat to support both long and short ones?
>>>>
>>>>         
>>> No....  there are only so many letters of the alphabet and we still
>>> have many long options without letters assigned to them that have
>>> no obvious shortening.
>>>       
>> No, if anything I'd drop short options and keep long, but there would
>> be a lot of pushback.
>>
>> Does it matter if it works, and several people here can understand it
>> well enough? Most people didn't even know we did this until today and
>> we surely didn't hear objections when it went in, so it clearly isn't
>> that bad...
>>
>> -Dan
>>
>>     
>
> Hmm this was about makepkg right? 
> makepkg --help | grep '-' | wc -l
> 24
>
> lowercase + uppercase gives you 52 options.
>   

Right...    We have these options without short version (e.g.)  --source 
--allsource --asroot .  Now -r -R -A -s are already used.  What would 
you choose?    the are 52 options but I doubt z,y,x... will ever make sense.

Anyway, this is not being changed.  If you can provide a single case 
where the old implementation parses options differently than the current 
bash implementation, I will be surprised and reward you with a cookie 
before fixing it.

This was discussed to death ages ago.  Go back and read about it.

Allan



More information about the pacman-dev mailing list