B ŖtC@sdZddddddddd d d d d ddddgZdZddlZddlZddlZddZyddlmZmZWn$e k rddZddZYnXeZ Gdd d e Z Gdd d e Z Gddde ZGddde ZGd dde ZGd!d"d"eZGd#d d ZGd$d d eZGd%d d eZd&d'Zd(d)Zee d*fee d*fee d+fee d,fd-Zd.d/Zd0dZd1ZGd2ddZd3Zd4ZGd5ddZ Gd6ddZ!Gd7dde!Z"Gd8dde!Z#d9d:Z$eZ%dS);z1.5.3Option make_option SUPPRESS_HELPSUPPRESS_USAGEValuesOptionContainer OptionGroup OptionParser HelpFormatterIndentedHelpFormatterTitledHelpFormatter OptParseError OptionErrorOptionConflictErrorOptionValueErrorBadOptionError check_choicea" Copyright (c) 2001-2006 Gregory P. Ward. All rights reserved. Copyright (c) 2002-2006 Python Software Foundation. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither the name of the author nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. NcCsd|jjt||fS)Nz<%s at 0x%x: %s>) __class____name__id)selfr+/opt/alt/python37/lib/python3.7/optparse.py_reprOsr)gettextngettextcCs|S)Nr)messagerrrr\srcCs|dkr |S|S)Nr)Zsingularpluralnrrrr_src@seZdZddZddZdS)r cCs ||_dS)N)msg)rr rrr__init__hszOptParseError.__init__cCs|jS)N)r )rrrr__str__kszOptParseError.__str__N)r __module__ __qualname__r!r"rrrrr gsc@seZdZddZddZdS)r cCs||_t||_dS)N)r str option_id)rr optionrrrr!uszOptionError.__init__cCs |jrd|j|jfS|jSdS)Nz option %s: %s)r&r )rrrrr"yszOptionError.__str__N)rr#r$r!r"rrrrr osc@s eZdZdS)rN)rr#r$rrrrrsc@s eZdZdS)rN)rr#r$rrrrrsc@seZdZddZddZdS)rcCs ||_dS)N)opt_str)rr(rrrr!szBadOptionError.__init__cCstd|jS)Nzno such option: %s)_r()rrrrr"szBadOptionError.__str__N)rr#r$r!r"rrrrrsc@seZdZddZddZdS)AmbiguousOptionErrorcCst||||_dS)N)rr! possibilities)rr(r+rrrr!s zAmbiguousOptionError.__init__cCstd|jd|jfS)Nzambiguous option: %s (%s?)z, )r)r(joinr+)rrrrr"szAmbiguousOptionError.__str__N)rr#r$r!r"rrrrr*sr*c@seZdZdZddZddZddZdd Zd d Zd d Z ddZ ddZ ddZ ddZ ddZddZddZddZddZd S)!r Znonec Csd|_||_|dkrLyttjd}Wnttfk rBd}YnX|d8}||_t|t |d|d|_ |_ d|_ d|_ d|_||_d|_i|_d|_d|_dS) NCOLUMNSPrz%defaultz%s %sz%s=%s)parserindent_incrementintosenvironKeyError ValueErrorwidthminmax help_positionmax_help_positioncurrent_indentlevel help_width short_first default_tagoption_strings_short_opt_fmt _long_opt_fmt)rr2r<r8r@rrrr!s$  zHelpFormatter.__init__cCs ||_dS)N)r1)rr1rrr set_parserszHelpFormatter.set_parsercCs&|dkrtd|d|d|_dS)N) z/invalid metavar delimiter for short options: %rz%s)r7rC)rdelimrrrset_short_opt_delimiters z%HelpFormatter.set_short_opt_delimitercCs&|dkrtd|d|d|_dS)N)=rGz.invalid metavar delimiter for long options: %rz%s)r7rD)rrHrrrset_long_opt_delimiters z$HelpFormatter.set_long_opt_delimitercCs"|j|j7_|jd7_dS)Nr)r=r2r>)rrrrindentszHelpFormatter.indentcCs"|j|j8_|jd8_dS)Nr)r=r2r>)rrrrdedentszHelpFormatter.dedentcCs tddS)Nzsubclasses must implement)NotImplementedError)rusagerrr format_usageszHelpFormatter.format_usagecCs tddS)Nzsubclasses must implement)rN)rheadingrrrformat_headingszHelpFormatter.format_headingcCs.t|j|jd}d|j}tj||||dS)N rG)initial_indentsubsequent_indent)r:r8r=textwrapfill)rtext text_widthrLrrr _format_texts  zHelpFormatter._format_textcCs|r||dSdSdS)N rF)rZ)r descriptionrrrformat_descriptionsz HelpFormatter.format_descriptioncCs|rd||dSdSdS)Nr[rF)rZ)repilogrrr format_epilogszHelpFormatter.format_epilogcCsP|jdks|js|jS|jj|j}|tks6|dkr<|j}|j|jt |S)N) r1rAhelpdefaultsgetdest NO_DEFAULTNO_DEFAULT_VALUEreplacer%)rr'Z default_valuerrrexpand_defaults zHelpFormatter.expand_defaultcsg}j|}jjd}t||krBdjd|f}j}ndjd||f}d}|||jr|}t|j }|d|d|df| fdd|ddDn|d d kr|d d |S) Nr/z%*s%s rFz %*s%-*s rcsg|]}djd|fqS)z%*s%s rF)r;).0line)rrr Esz/HelpFormatter.format_option..rr[) rBr;r=lenappendr`rgrVwrapr?extendr,)rr'resultoptsZ opt_width indent_first help_text help_linesr)rr format_option(s$      zHelpFormatter.format_optioncCs|d}x6|jD],}||}||j|<t|t||j}qW|xF|jD]<}x6|jD],}||}||j|<t|t||j}q`WqTW||t |d|j |_ t|j |j d|_ dS)Nrr/rS)rL option_listformat_option_stringsrBr:rlr= option_groupsrMr9r<r;r8r?)rr1Zmax_lenoptstringsgrouprrrstore_option_stringsKs        z"HelpFormatter.store_option_stringscst|rF|jp|jfdd|jD}fdd|jD}n |j}|j}jrb||}n||}d|S)Ncsg|]}j|fqSr)rC)rhZsopt)metavarrrrrjasz7HelpFormatter.format_option_strings..csg|]}j|fqSr)rD)rhZlopt)r}rrrrjcsz, ) takes_valuer}rcupper _short_opts _long_optsr@r,)rr'Z short_optsZ long_optsrqr)r}rrrw]s     z#HelpFormatter.format_option_stringsN)rr#r$rer!rErIrKrLrMrPrRrZr]r_rgrur|rwrrrrr s +  #c@s&eZdZd ddZddZd d ZdS) r r/NrcCst|||||dS)N)r r!)rr2r<r8r@rrrr!tszIndentedHelpFormatter.__init__cCs td|S)Nz Usage: %s )r))rrOrrrrP|sz"IndentedHelpFormatter.format_usagecCsd|jd|fS)Nz%*s%s: rF)r=)rrQrrrrRsz$IndentedHelpFormatter.format_heading)r/rNr)rr#r$r!rPrRrrrrr ps  c@s&eZdZd ddZddZdd ZdS) r rrNcCst|||||dS)N)r r!)rr2r<r8r@rrrr!szTitledHelpFormatter.__init__cCsd|td|fS)Nz%s %s ZUsage)rRr))rrOrrrrPsz TitledHelpFormatter.format_usagecCsd|d|jt|fS)Nz%s %s z=-)r>rl)rrQrrrrRsz"TitledHelpFormatter.format_heading)rrNr)rr#r$r!rPrRrrrrr s  cCsh|dddkrd}nD|dddkrDd}|ddp@d}n|dddkrZd}nd}|||S) Nr/0xZ0b0r )lower)valtyperadixrrr _parse_numsrcCs t|tS)N)rr3)rrrr _parse_intsrZintegerzfloating-pointcomplex)r3longfloatrcCsFt|j\}}y||Stk r@ttd|||fYnXdS)Nzoption %s: invalid %s value: %r) _builtin_cvtrr7rr))r'ryvalueZcvtZwhatrrr check_builtins rcCs:||jkr|Sdtt|j}ttd|||fdS)Nz, z.option %s: invalid choice: %r (choose from %s))choicesr,mapreprrr))r'ryrrrrrrs  )ZNOZDEFAULTc @seZdZddddddddd d d d g Zd ZdZdZdZdZdZ e e e e e dZ dZ ddZddZddZddZddZdd Zd!d"Zd#d$Zd%d&Zd'd(Zd)d*ZeeeeeeegZ d+d,ZeZd-d.Zd/d0Zd1d2Zd3d4Zd5d6Z d7d8Z!dS)9ractionrrcdefaultnargsconstrcallback callback_argscallback_kwargsr`r}) store store_const store_true store_falserm append_constcountrr`version)rrrrrmrr)rrmr)rrm)rr)stringr3rrrchoice)r3rrrrNcOsFg|_g|_||}||||x|jD] }||q2WdS)N)rr_check_opt_strings_set_opt_strings _set_attrs CHECK_METHODS)rrqattrscheckerrrrr!4s    zOption.__init__cCsdd|D}|std|S)NcSsg|] }|r|qSrr)rhryrrrrjKsz-Option._check_opt_strings..z+at least one option string must be supplied) TypeError)rrqrrrrGszOption._check_opt_stringscCsx|D]}t|dkr&td||qt|dkrf|ddkrJ|ddksXtd|||j|q|dddkr|ddkstd|||j|qWdS) Nr/z>invalid option string %r: must be at least two characters longr-rzMinvalid short option string %r: must be of the form -x, (x any non-dash char)z--zGinvalid long option string %r: must start with --, followed by non-dash)rlr rrmr)rrqryrrrrPs$    zOption._set_opt_stringscCszxP|jD]F}||kr,t||||||=q|dkrBt||tqt||dqW|rvt|}tdd||dS)Nrzinvalid keyword arguments: %sz, )ATTRSsetattrrdsortedkeysr r,)rrattrrrrres   zOption._set_attrscCs2|jdkrd|_n|j|jkr.td|j|dS)Nrzinvalid action: %r)rACTIONSr )rrrr _check_actionxs  zOption._check_actioncCs|jdkr0|j|jkr|jdk r(d|_qd|_n^t|jtrF|jj|_|jdkrVd|_|j|jkrrtd|j||j|jkrtd|j|dS)Nrrr%zinvalid option type: %rz$must not supply a type for action %r) rrALWAYS_TYPED_ACTIONSr isinstancerTYPESr TYPED_ACTIONS)rrrr _check_type~s        zOption._check_typecCsr|jdkrT|jdkr td|qnt|jttfsntdtt|jdd|n|jdk rntd|j|dS)Nrz/must supply a list of choices for type 'choice'z1choices must be a list of strings ('%s' supplied)'rz#must not supply choices for type %r)rrr rtuplelistr%split)rrrr _check_choices     zOption._check_choicecCs\|j|jkp|jdk }|jdkrX|rX|jrH|jddddd|_n|jdd|_dS)Nrr/rr)r)r STORE_ACTIONSrrcrrfr)rr~rrr _check_dests   zOption._check_destcCs*|j|jkr&|jdk r&td|j|dS)Nz*'const' must not be supplied for action %r)r CONST_ACTIONSrr )rrrr _check_constszOption._check_constcCs<|j|jkr|jdkr8d|_n|jdk r8td|j|dS)Nrz*'nargs' must not be supplied for action %r)rrrr )rrrr _check_nargss   zOption._check_nargscCs|jdkrrt|js$td|j||jdk rJt|jtsJtd|j||jdk rt|jtstd|j|nB|jdk rtd|j||jdk rtd||jdk rtd|dS)Nrzcallback not callable: %rz3callback_args, if supplied, must be a tuple: not %rz4callback_kwargs, if supplied, must be a dict: not %rz.callback supplied (%r) for non-callback optionz.callback_args supplied for non-callback optionz0callback_kwargs supplied for non-callback option) rcallablerr rrrrdict)rrrr_check_callbacks0           zOption._check_callbackcCsd|j|jS)N/)r,rr)rrrrr"szOption.__str__cCs |jdk S)N)r)rrrrr~szOption.takes_valuecCs|jr|jdS|jdSdS)Nr)rr)rrrrget_opt_strings zOption.get_opt_stringcCs*|j|j}|dkr|S||||SdS)N) TYPE_CHECKERrbr)rryrrrrr check_valueszOption.check_valuecs:|dk r6jdkr|Stfdd|DSdS)Nrcsg|]}|qSr)r)rhv)ryrrrrjsz(Option.convert_value..)rrr)rryrr)ryrr convert_values  zOption.convert_valuecCs$|||}||j|j||||S)N)r take_actionrrc)rryrvaluesr1rrrprocesss zOption.processc Cs:|dkrt|||n|dkr2t|||jn|dkrHt||dn|dkr^t||dn|dkrz||g|n|dkr||g|jn|d krt||||d d n||d kr|jpd }|jpi}|j||||f||nF|dkr ||n*|dkr(| |nt d|j d S)NrrrTrFrmrrrrrrr`rzunknown action %r) rr ensure_valuermrrr print_helpexit print_versionr7r) rrrcryrrr1argskwargsrrrrs4      zOption.take_action)"rr#r$rrrrrrrrrrrr!rrrrrrrrrrr"r__repr__r~rrrrrrrrrrsd       Z SUPPRESSHELPZ SUPPRESSUSAGEc@s^eZdZdddZddZeZddZdd Zd d Z d d Z dddZ dddZ ddZ dS)rNcCs*|r&x |D]\}}t|||qWdS)N)itemsr)rrarrrrrr!9szValues.__init__cCs t|jS)N)r%__dict__)rrrrr">szValues.__str__cCs2t|tr|j|jkSt|tr*|j|kStSdS)N)rrrrNotImplemented)rotherrrr__eq__Cs     z Values.__eq__cCs:x4t|D](}||kr ||}|dk r t|||q WdS)N)dirr)rrrZdvalrrr_update_carefulKs zValues._update_carefulcCs|j|dS)N)rupdate)rrrrr _update_looseXszValues._update_loosecCs8|dkr||n |dkr(||n td|dS)NcarefulZloosezinvalid update mode: %r)rrr7)rrmoderrr_update`s   zValues._updatercCs&t|tj|}|t||dS)N) __import__sysmodulesrvars)rmodnamermodrrr read_modulehs zValues.read_modulecCs&i}tt|||||dS)N)execopenreadr)rfilenamerrrrr read_filemszValues.read_filecCs.t||rt||dkr$t|||t||S)N)hasattrgetattrr)rrrrrrrrs zValues.ensure_value)N)r)r)rr#r$r!r"rrrrrrrrrrrrrr7s    c@seZdZddZddZddZddZd d Zd d Zd dZ ddZ ddZ ddZ ddZ ddZddZddZddZdd Zd!S)"rcCs&|||_||||dS)N)_create_option_list option_classset_conflict_handlerset_description)rrconflict_handlerr\rrrr!s zOptionContainer.__init__cCsi|_i|_i|_dS)N) _short_opt _long_optra)rrrr_create_option_mappingssz'OptionContainer._create_option_mappingscCs|j|_|j|_|j|_dS)N)rrra)rr1rrr_share_option_mappingssz&OptionContainer._share_option_mappingscCs|dkrtd|||_dS)N)errorresolvez$invalid conflict_resolution value %r)r7r)rhandlerrrrrs z$OptionContainer.set_conflict_handlercCs ||_dS)N)r\)rr\rrrrszOptionContainer.set_descriptioncCs|jS)N)r\)rrrrget_descriptionszOptionContainer.get_descriptioncCs|`|`|`dS)N)rrra)rrrrdestroyszOptionContainer.destroycCsg}x,|jD]"}||jkr |||j|fq Wx,|jD]"}||jkr:|||j|fq:W|r|j}|dkrtdddd|D|nh|dkrx^|D]V\}}|dr|j ||j|=n|j ||j|=|js|js|j j |qWdS)Nrz conflicting option string(s): %sz, cSsg|] }|dqS)rr)rhcorrrrjsz3OptionContainer._check_conflict..rz--) rrrmrrrrr, startswithremove containerrv)rr'Z conflict_optsryrZc_optionrrr_check_conflicts.         zOptionContainer._check_conflictcOst|dtr|j||}n8t|dkrL|sL|d}t|tsTtd|ntd|||j|||_ x|j D]}||j |<qxWx|j D]}||j |<qW|jdk r|jtk r|j|j|j<n|j|jkrd|j|j<|S)Nrrznot an Option instance: %rzinvalid arguments)rr%rrlrrrrvrmrrrrrrcrrdra)rrrr'ryrrr add_options(         zOptionContainer.add_optioncCsx|D]}||qWdS)N)r)rrvr'rrr add_optionss zOptionContainer.add_optionscCs|j|p|j|S)N)rrbr)rr(rrr get_options zOptionContainer.get_optioncCs||jkp||jkS)N)rr)rr(rrr has_option s zOptionContainer.has_optioncCsv|j|}|dkr |j|}|dkr4td|x|jD] }|j|=qZ!d?d@Z"dRdAdBZ#dCdDZ$dSdEdFZ%dTdGdHZ&dIdJZ'dUdKdLZ(dVdMdNZ)dS)WrNrTc Csrt||||||| |_||_d|_d|_|dkr@t}||_|j || |_ |j ||d| dS)NT)add_help) rr! set_usageprograllow_interspersed_argsprocess_default_valuesr r rEr^_populate_option_list_init_parsing_state) rrOrvrrrr\r Zadd_help_optionrr^rrrr!s    zOptionParser.__init__cCs2t|x|jD] }|qW|`|`|`dS)N)rrrxrvr )rr{rrrrs    zOptionParser.destroycCsg|_g|_|dS)N)rvrxr)rrrrrsz OptionParser._create_option_listcCs|jdddtdddS)Nz-hz--helpr`zshow this help message and exit)rr`)rr))rrrr_add_help_optionszOptionParser._add_help_optioncCs|jddtdddS)Nz --versionrz&show program's version number and exit)rr`)rr))rrrr_add_version_optionsz OptionParser._add_version_optioncCs>|jr||j|r |||jr.||r:|dS)N)standard_option_listrrrr)rrvrrrrrs  z"OptionParser._populate_option_listcCsd|_d|_d|_dS)N)rargslargsr)rrrrrsz OptionParser._init_parsing_statecCsL|dkrtd|_n4|tkr$d|_n$|drB|dd|_n||_dS)Nz%prog [options]zusage: )r)rOrrr)rrOrrrrs zOptionParser.set_usagecCs d|_dS)NT)r)rrrrenable_interspersed_argssz%OptionParser.enable_interspersed_argscCs d|_dS)NF)r)rrrrdisable_interspersed_argssz&OptionParser.disable_interspersed_argscCs ||_dS)N)r)rrrrrset_process_default_values sz'OptionParser.set_process_default_valuescCs||j|<dS)N)ra)rrcrrrr set_defaultszOptionParser.set_defaultcKs|j|dS)N)rar)rrrrr set_defaultsszOptionParser.set_defaultscCs.|jdd}x|jD]}||jqW|S)N)rvrxro)roptionsr{rrr_get_all_optionss zOptionParser._get_all_optionscCsd|jst|jS|j}x@|D]4}||j}t|tr$| }| ||||j<q$Wt|S)N) rrracopyr"rbrcrr%rr)rrar'rr(rrrget_default_valuess    zOptionParser.get_default_valuescOszt|dtr t|f||}nJt|dkrb|sb|d}t|tsNtd||j|k rjtdntd|j||S)Nrrznot an OptionGroup instance: %rz"invalid OptionGroup (wrong parser)zinvalid arguments) rr%rrlrr1r7rxrm)rrrr{rrradd_option_group+s     zOptionParser.add_option_groupcCs0|j|p|j|}|r,|j|k r,|jSdS)N)rrbrr)rr(r'rrrget_option_group;s   zOptionParser.get_option_groupcCs&|dkrtjddS|ddSdS)Nr)rargv)rrrrr _get_argsEszOptionParser._get_argsc Cs||}|dkr|}||_g|_}||_y||||}Wn4ttfk rv}z|t |Wdd}~XYnX||}| ||S)N) r(r$rrr _process_argsrrrr% check_values)rrrrrstoperrrrr parse_argsKs    zOptionParser.parse_argscCs||fS)Nr)rrrrrrr*rs zOptionParser.check_valuescCsx|r|d}|dkr |d=dS|dddkr>|||q|dddkrht|dkrh|||q|jr|||d=qdSqWdS)Nrz--r/rr)_process_long_optrl_process_short_optsrrm)rrrrargrrrr)s  zOptionParser._process_argscCs t||jS)N) _match_abbrevr)rryrrr_match_long_optszOptionParser._match_long_optc Cs|d}d|kr4|dd\}}|d|d}n|}d}||}|j|}|r|j}t||kr|t dd|||dq|dkr|d} qt |d|} |d|=n|r|t d |nd} | || ||dS) NrrJrTFz.%(option)s option requires %(number)d argumentz/%(option)s option requires %(number)d arguments)r'numberz%s option does not take a value) poprinsertr2rr~rrlrrrr)r) rrrr0ryZnext_argZhad_explicit_valuer'rrrrrr.s0       zOptionParser._process_long_optc Cs|d}d}d}x|ddD]}d|}|j|}|d7}|sLt||r|t|krx|d||dd}|j} t|| kr|t dd| || dq| dkr|d} qt |d| } |d| =nd} | || |||r Pq WdS) NrFrrTz.%(option)s option requires %(number)d argumentz/%(option)s option requires %(number)d arguments)r'r3) r4rrbrr~rlr5rrrrr) rrrr0r+iZchryr'rrrrrr/s6      z OptionParser._process_short_optscCs&|jdkrtjtjdS|jSdS)Nr)rr4pathbasenamerr')rrrr get_prog_names zOptionParser.get_prog_namecCs|d|S)Nz%prog)rfr9)rsrrrexpand_prog_nameszOptionParser.expand_prog_namecCs ||jS)N)r;r\)rrrrrszOptionParser.get_descriptionrcCs|rtj|t|dS)N)rstderrwriter)rstatusr rrrrs zOptionParser.exitcCs(|tj|dd||fdS)Nr/z%s: error: %s ) print_usagerr<rr9)rr rrrrs zOptionParser.errorcCs"|jr|j||jSdSdS)NrF)rOr rPr;)rrrr get_usage#szOptionParser.get_usagecCs|jrt||ddS)N)file)rOprintr@)rrArrrr?*s zOptionParser.print_usagecCs|jr||jSdSdS)NrF)rr;)rrrr get_version6s zOptionParser.get_versioncCs|jrt||ddS)N)rA)rrBrC)rrArrrr<szOptionParser.print_versioncCs|dkr|j}||g}||td||jrZ|t|||dx(|j D]}|| ||dqbW| d |ddS)NZOptionsr[rFrk) r r|rmrRr)rLrvrr rxr rMr,)rr rpr{rrrr Gs   zOptionParser.format_option_helpcCs ||jS)N)r_r^)rr rrrr_XszOptionParser.format_epilogcCsn|dkr|j}g}|jr*||d|jrD|||d||||||d|S)Nr[rF) r rOrmr@r\r]r r_r,)rr rprrrr [szOptionParser.format_helpcCs |dkrtj}||dS)N)rstdoutr=r )rrArrrrgszOptionParser.print_help)T)NN)rN)N)N)N)N)N)*rr#r$rrr!rrrrrrrrrrrr r"r$r%r&r(r-r*r)r2r.r/r9r;rrrr@r?rCrr r_r rrrrrrRs^F      ' 3 $)     csZ|kr Sfdd|D}t|dkr6|dS|sDtn|t|dS)Ncsg|]}|r|qSr)r)rhZword)r:rrrjsz!_match_abbrev..rr)rrlrsortr*)r:Zwordmapr+r)r:rr1ts  r1)& __version____all__Z __copyright__rr4rVrrr ImportErrorr) Exceptionr r rrrr*r r r rrrrrrrrdrrrrrrrr1rrrrrs|    P     uA=&