3 ­ž‘eM ã@sDddlmZddlmZmZmZdd„ZGdd„deƒZdd„Zd S) é)ÚDistutilsOptionError)Ú edit_configÚ option_baseÚ config_filecCs8xdD]}||krt|ƒSqW|jƒ|gkr4t|ƒS|S)z4Quote an argument for later parsing by shlex.split()ú"ú'ú\ú#)rrrr )ÚreprÚsplit)ÚargÚc©rú>/tmp/pip-build-vlmub77e/setuptools/setuptools/command/alias.pyÚshquotes   rc@sHeZdZdZdZdZdgejZejdgZdd„Z d d „Z d d „Z d S)Úaliasz3Define a shortcut that invokes one or more commandsz0define a shortcut to invoke one or more commandsTÚremoveÚrúremove (unset) the aliascCstj|ƒd|_d|_dS)N)rÚinitialize_optionsÚargsr)Úselfrrrrs zalias.initialize_optionscCs*tj|ƒ|jr&t|jƒdkr&tdƒ‚dS)NézFMust specify exactly one argument (the alias name) when using --remove)rÚfinalize_optionsrÚlenrr)rrrrr!s zalias.finalize_optionscCsÔ|jjdƒ}|jsDtdƒtdƒx|D]}tdt||ƒƒq(WdSt|jƒdkr”|j\}|jrfd}q¸||kr‚tdt||ƒƒdStd|ƒdSn$|jd}djtt |jdd…ƒƒ}t |j d||ii|j ƒdS) NÚaliaseszCommand Aliasesz---------------zsetup.py aliasrz No alias definition found for %rrú ) Ú distributionÚget_option_dictrÚprintÚ format_aliasrrÚjoinÚmaprrÚfilenameÚdry_run)rrrÚcommandrrrÚrun)s&    z alias.runN)rrr) Ú__name__Ú __module__Ú __qualname__Ú__doc__Ú descriptionZcommand_consumes_argumentsrÚ user_optionsÚboolean_optionsrrr&rrrrrs rcCsZ||\}}|tdƒkrd}n,|tdƒkr0d}n|tdƒkrBd}nd|}||d|S) NÚglobalz--global-config Úuserz--user-config ÚlocalÚz --filename=%rr)r)ÚnamerÚsourcer%rrrr Ds    r N) Zdistutils.errorsrZsetuptools.command.setoptrrrrrr rrrrÚs  4