ó
    Ë5žj§  ã                   ó  • % S r SS/rSSKrSSKrSSKrSSKJr  SSKrSSK	J
r
Jr  SSKrSSKrSSKJr  SSKrSSKrSSKJrJr  SSKJr  SS	KJrJrJrJrJrJrJrJ r J!r!J"r"J#r#J$r$  SS
K%J&r&J'r'J(r(J)r)J*r*  \ (       a  SSK	J+r+  SSK,J-r-  \"" SSS9r.\"" S\/\0\1\2\35      r4\Rj                  SS S:  a	  SSK6J7r7  \7r8OSSKJ7r7  \7\/\\4   4   r8\Rr                  " \:5      r;Sr<\'\=S'    \R|                  " S5      r? \R|                  " S5      r@ \R|                  " S5      rA  " S S\R„                  5      rCS\S\*4   S\S\*4   4S jrDS\S\*4   S\S\*4   4S jrE " S  S\\.   5      rF " S! S"\85      rGS#\&S\/4S$ jrH " S% S\R’                  \CS&9rJg)'z3Parser for reading and writing configuration files.ÚGitConfigParserÚSectionConstrainté    N)Úwraps)ÚBufferedReaderÚIOBase)ÚdefencÚ
force_text)ÚLockFile)ÚAnyÚCallableÚGenericÚIOÚListÚDictÚSequenceÚTYPE_CHECKINGÚTupleÚTypeVarÚUnionÚcast)ÚLit_config_levelsÚConfigLevels_TupÚPathLikeÚassert_neverÚ_T)ÚBytesIO)ÚRepoÚT_ConfigParser)ÚboundÚT_OMD_valueé   )r!   é   é   )ÚOrderedDict)ÚsystemÚuserÚglobalÚ
repositoryÚCONFIG_LEVELSzL(?<=includeIf )\"(gitdir|gitdir/i|onbranch|hasconfig:remote\.\*\.url):(.+)\"z
[\r\n\x00]z^[A-Za-z0-9_.-]+$c                   óJ   ^ • \ rS rSrSrS\S\S\\\4   SS 4U 4S jjr	Sr
U =r$ )	ÚMetaParserBuilderéR   z[Utility class wrapping base-class methods into decorators that assure read-only
properties.ÚnameÚbasesÚclsdictÚreturnc                 ó
  >• SnXC;   aj  X4   nU H`  nS [         R                  " U[         R                  5       5       nU H+  u  p‰Xƒ;   a  M  [        U	5      n
X…;   a  [	        U
5      n
X£U'   M-     Mb     [
        TU ]  XX#5      nU$ )z Equip all base-class methods with a needs_values decorator, and all non-const
methods with a :func:`set_dirty_and_flush_changes` decorator in addition to
that.
Ú_mutating_methods_c              3   óZ   #   • U  H!  oS    R                  S5      (       a  M  Uv •  M#     g7f)r   Ú_N©Ú
startswith)Ú.0Úts     Ú˜C:\Users\johnn\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.13_qbz5n2kfra8p0\LocalCache\local-packages\Python313\site-packages\git/config.pyÚ	<genexpr>Ú,MetaParserBuilder.__new__.<locals>.<genexpr>_   s&   é € ÐnÒ&Q Ð[\ÑY]×YhÑYhÐil×YmŸ1™1Ò&Qùs   ‚+¢	+)ÚinspectÚ
getmembersÚ	isroutineÚneeds_valuesÚset_dirty_and_flush_changesÚsuperÚ__new__)Úclsr-   r.   r/   ÚkmmÚmutating_methodsÚbaseÚmethodsÚmethod_nameÚmethodÚmethod_with_valuesÚnew_typeÚ	__class__s               €r9   rB   ÚMetaParserBuilder.__new__V   s’   ø€ ð
 #ˆØ‹>Ø&™|ÐÛ�Ùn¤g×&8Ò&8¸¼w×?PÑ?PÔ&QÓn�Û+2Ñ'�KØ"Ó-Ù Ü)5°fÓ)=Ð&Ø"Ó6Ü-HÐI[Ó-\Ð*ð ,>˜KÓ(ó ,3ñ ô ‘7‘? 3¨eÓ=ˆØˆó    © )Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__Ústrr   r   r   rB   Ú__static_attributes__Ú__classcell__©rL   s   @r9   r+   r+   R   s7   ø† ñð˜3ð  uð °t¸CÀ¸H±~ð ÐJ]÷ õ rN   r+   Úfunc.r0   c           	      ó\   ^ • [        T 5      SSS[        S[        S[        4U 4S jj5       nU$ )zUReturn a method for ensuring we read values (on demand) before we try to access
them.Úselfr   ÚargsÚkwargsr0   c                 ó<   >• U R                  5         T" U /UQ70 UD6$ ©N)Úread)r[   r\   r]   rY   s      €r9   Úassure_data_presentÚ)needs_values.<locals>.assure_data_presentu   s!   ø€ à�	‰	ŒÙ�DÐ*˜4Ò* 6Ñ*Ð*rN   )r   r   r   )rY   ra   s   ` r9   r?   r?   q   sA   ø€ ô ˆ4ƒ[ð+Ð"3ð +¼Cð +Ì3ð +ÔSUö +ó ð+ð
 ÐrN   Únon_const_funcc                 ób   ^ • SSS[         S[         S[        4U 4S jjnT R                  Ul        U$ )z©Return a method that checks whether given non constant function may be called.

If so, the instance will be set dirty. Additionally, we flush the changes right to
disk.
r[   r   r\   r]   r0   c                 óN   >• T" U /UQ70 UD6nSU l         U R                  5         U$ )NT)Ú_dirtyÚwrite)r[   r\   r]   Úrvalrc   s       €r9   Úflush_changesÚ2set_dirty_and_flush_changes.<locals>.flush_changes…   s,   ø€ Ù˜dÐ4 TÒ4¨VÑ4ˆØˆŒØ�
‰
ŒØˆrN   )r   r   rP   )rc   ri   s   ` r9   r@   r@   ~   s;   ø€ ðÐ-ð ´cð ÄSð ÌR÷ ð ,×4Ñ4€MÔØÐrN   c                   óÀ   ^ • \ rS rSrSrSrSrS\S\SS4S	 jr	SS
 jr
S\S\4U 4S jjrS\S\S\S\4S jr\S\4S j5       rSS jrSS jrS\S\S\SS4S jrSrU =r$ )r   é�   a  Constrains a ConfigParser to only option commands which are constrained to
always use the section we have been initialized with.

It supports all ConfigParser methods that operate on an option.

:note:
    If used as a context manager, will release the wrapped ConfigParser.
©Ú_configÚ_section_name)Ú	get_valueÚ	set_valueÚgetÚsetÚgetintÚgetfloatÚ
getbooleanÚ
has_optionÚremove_sectionÚremove_optionÚoptionsÚconfigÚsectionr0   Nc                 ó   • Xl         X l        g r_   rm   )r[   r{   r|   s      r9   Ú__init__ÚSectionConstraint.__init__ª   s   € ØŒØ$ÕrN   c                 ó8   • U R                   R                  5         g r_   ©rn   Úrelease©r[   s    r9   Ú__del__ÚSectionConstraint.__del__®   s   € ð 	�‰×ÑÕrN   Úattrc                 óT   >^ ^• TT R                   ;   a  UU 4S j$ [        TT ]	  T5      $ )Nc                  ó0   >• TR                   " T/U Q70 UD6$ r_   )Ú_call_config)r\   r]   r†   r[   s     €€r9   Ú<lambda>Ú/SectionConstraint.__getattr__.<locals>.<lambda>¶   s   ø€ ¨4×+<Ò+<¸TÐ+SÀDÒ+SÈFÒ+SrN   )Ú_valid_attrs_rA   Ú__getattribute__)r[   r†   rL   s   ``€r9   Ú__getattr__ÚSectionConstraint.__getattr__´   s'   ú€ Ø�4×%Ñ%Ó%ÝSÐSÜ‰wÑ'¨Ó-Ð-rN   rI   r\   r]   c                 óV   • [        U R                  U5      " U R                  /UQ70 UD6$ )z\Call the configuration at the given method which must take a section name as
first argument.)Úgetattrrn   ro   )r[   rI   r\   r]   s       r9   r‰   ÚSectionConstraint._call_config¹   s*   € ô �t—|‘| VÔ,¨T×-?Ñ-?ÐQÀ$ÒQÈ&ÑQÐQrN   c                 ó   • U R                   $ )z*return: ConfigParser instance we constrain)rn   rƒ   s    r9   r{   ÚSectionConstraint.config¾   s   € ð �|‰|ÐrN   c                 ó6   • U R                   R                  5       $ )zaEquivalent to :meth:`GitConfigParser.release`, which is called on our
underlying parser instance.r�   rƒ   s    r9   r‚   ÚSectionConstraint.releaseÃ   s   € ð �|‰|×#Ñ#Ó%Ð%rN   c                 ó:   • U R                   R                  5         U $ r_   )rn   Ú	__enter__rƒ   s    r9   r˜   ÚSectionConstraint.__enter__È   s   € Ø�‰×ÑÔ ØˆrN   Úexception_typeÚexception_valueÚ	tracebackc                 ó<   • U R                   R                  XU5        g r_   )rn   Ú__exit__)r[   rš   r›   rœ   s       r9   rž   ÚSectionConstraint.__exit__Ì   s   € Ø�‰×Ñ˜n¸yÕIrN   ©r0   N)r0   z!SectionConstraint[T_ConfigParser])rP   rQ   rR   rS   rT   Ú	__slots__rŒ   r   rU   r~   r„   r   rŽ   r‰   Úpropertyr{   r‚   r˜   rž   rV   rW   rX   s   @r9   r   r   �   sÀ   ø† ñð -€Ið€Mð%˜~ð %¸ð %Àô %ôð. ð .¨÷ .ð
R 3ð R¨sð R¸cð RÀcô Rð
 ð˜ó ó ðô&ô
ðJ sð J¸Sð JÈSð JÐUY÷ Jò JrN   c            	       óZ  ^ • \ rS rSrSrS\S\SS4U 4S jjrS\S\SS4U 4S jjr	S\S	\
\   SS4U 4S
 jjrS\S\4U 4S jjrS\S\4U 4S jjrS\S\SS4U 4S jjrSS\S\\S4   S\\S4   4U 4S jjjrS\S\
\   4U 4S jjrS\
\\\4      4S jrS\
\\\
\   4      4S jrSrU =r$ )Ú_OMDéÐ   zOrdered multi-dict.ÚkeyÚvaluer0   Nc                 ó&   >• [         TU ]  X/5        g r_   ©rA   Ú__setitem__©r[   r¦   r§   rL   s      €r9   rª   Ú_OMD.__setitem__Ó   s   ø€ Ü‰Ñ˜C Õ)rN   c                 ón   >• X;  a  [         TU ]  X/5        g [         TU ]	  U5      R                  U5        g r_   )rA   rª   Ú__getitem__Úappendr«   s      €r9   ÚaddÚ_OMD.addÖ   s2   ø€ Ø‹?Ü‰GÑ  WÔ-Øä‰Ñ˜CÓ ×'Ñ'¨Õ.rN   Úvaluesc                 ó$   >• [         TU ]  X5        g r_   r©   )r[   r¦   r²   rL   s      €r9   ÚsetallÚ_OMD.setallÝ   s   ø€ Ü‰Ñ˜CÕ(rN   c                 ó(   >• [         TU ]  U5      S   $ ©Néÿÿÿÿ©rA   r®   ©r[   r¦   rL   s     €r9   r®   Ú_OMD.__getitem__à   ó   ø€ Ü‰wÑ" 3Ó'¨Ñ+Ð+rN   c                 ó(   >• [         TU ]  U5      S   $ r·   r¹   rº   s     €r9   ÚgetlastÚ_OMD.getlastã   r¼   rN   c                 óX   >• X;  a  [         TU ]  X/5        g [         TU ]	  U5      nX#S'   g r·   )rA   rª   r®   )r[   r¦   r§   ÚpriorrL   s       €r9   ÚsetlastÚ_OMD.setlastæ   s0   ø€ Ø‹?Ü‰GÑ  WÔ-Øä‘Ñ# CÓ(ˆØˆbŠ	rN   Údefaultc                 ó*   >• [         TU ]  X/5      S   $ r·   )rA   rr   )r[   r¦   rÄ   rL   s      €r9   rr   Ú_OMD.getî   s   ø€ Ü‰w‰{˜3 	Ó*¨2Ñ.Ð.rN   c                 ó"   >• [         TU ]  U5      $ r_   r¹   rº   s     €r9   ÚgetallÚ_OMD.getallñ   s   ø€ Ü‰wÑ" 3Ó'Ð'rN   c                 ó8   • U  Vs/ s H  oX   4PM
     sn$ s  snf )z"List of (key, last value for key).rO   ©r[   Úks     r9   ÚitemsÚ
_OMD.itemsô   s   € á&*Ó+¢d �D‘G“¡dÑ+Ð+ùÒ+s   …c                 óR   • U  Vs/ s H  oU R                  U5      4PM     sn$ s  snf )z&List of (key, list of values for key).)rÈ   rË   s     r9   Ú	items_allÚ_OMD.items_allø   s%   € á-1Ó2ªT¨�D—K‘K “NÓ#©TÑ2Ð2ùÒ2s   …$rO   r_   )rP   rQ   rR   rS   rT   rU   r   rª   r   r°   r   r´   r®   r¾   rÂ   r   rr   rÈ   r   rÍ   rÐ   rV   rW   rX   s   @r9   r¤   r¤   Ð   s  ø† Ùð*˜sð *¨2ð *°$÷ *ð/�sð / 3ð /¨4÷ /ð)˜#ð ) t¨B¡xð )°D÷ )ð,˜sð , s÷ ,ð,˜3ð , 3÷ ,ð˜3ð  sð ¨t÷ ñ/�sð / U¨2¨t¨8¡_ð /ÀÀbÈ$ÀhÁ÷ /ð /ð(˜#ð ( $ r¡(÷ (ð,�t˜E # r '™NÑ+ô ,ð3˜4  c¨4°©8 mÑ 4Ñ5÷ 3ò 3rN   r¤   Úconfig_levelc           	      ó@  • [         R                  S:X  a  U S:X  a  Sn U S:X  a  gU S:X  a›  [        R                  R	                  S5      =(       d5    [
        R                  " [        R                  R	                  SS5      S	5      n[
        R                  " [
        R                  " [
        R                  " US
S5      5      5      $ U S:X  a*  [
        R                  " [
        R                  " S5      5      $ U S:X  a  [        S5      e[        U [        SU < 35      5        g )NÚwin32r%   r'   z/etc/gitconfigr&   ÚXDG_CONFIG_HOMEÚHOMEÚ~z.configÚgitr{   z~/.gitconfigr(   zGNo repo to get repository configuration from. Use Repo._get_config_pathzInvalid configuration level: )ÚsysÚplatformÚosÚenvironrr   ÚospÚjoinÚnormpathÚ
expanduserÚ
ValueErrorr   )rÒ   Úconfig_homes     r9   Úget_config_pathrã   ý   sÛ   € ô ‡|�|�wÓ <°8Ó#;Øˆà�xÓØØ	˜Ó	Ü—j‘j—n‘nÐ%6Ó7×k¼3¿8º8ÄBÇJÁJÇNÁNÐSYÐ[^ÓD_ÐajÓ;kˆÜ�|Š|œCŸNšN¬3¯8ª8°KÀÈÓ+QÓRÓSÐSØ	˜Ó	!Ü�|Š|œCŸNšN¨>Ó:Ó;Ð;Ø	˜Ó	%ÜÐbÓcÐcô 	ØÜÐ6°|Ñ6FÐGÓHõ	
rN   c                   óP  ^ • \ rS rSrSr\r \R                  " S5      r	Sr
\R                  " \
5      r\R                  " \
S-   S-   5      rC
Sr      S=S	\S\S
\\\S
4      4   S\S\S\\S4   S\S   SS4S jjrS>S jrS>S jrS?S jrS\SS4S jrS>S jrS\S\4S jrS\\\\   4   S\SS4S jrS\\\ 4   4S jr!S\"\#\\4      4S jr$S>S jr%S\SS4S  jr&S!\S\"\#\\4      4U 4S" jjr'S!\S\"\#\\"\   4      4S# jr(\)S>S$ j5       r*S%\SS4S& jr+S@U 4S) jjr,\-S\4S* j5       r. SAS'\S+\S,\\ \/\\S4   S\\ \/\\4   4S- jjr0 SAS'\S+\S,\\ \/\\S4   S\"\\ \/\\4      4S. jjr1S/\S\\ \/\\4   4S0 jr2S1\\\\ \/\4   S\4S2 jr3S1\\\\ \/\4   S\4S3 jr4S4S(S5\SS4S6 jr5\)\6 SAS'\S+\S1\\\\ \/\S4   SS4U 4S7 jjj5       5       r7\)\6S'\S+\S1\\\\ \/\4   SS 4U 4S8 jj5       5       r8\)\6S'\S+\S1\\\\ \/\4   SS 4S9 j5       5       r9S'\S:\SS 4U 4S; jjr:S<r;U =r<$ )Br   i  a¤  Implements specifics required to read git style configuration files.

This variation behaves much like the :manpage:`git-config(1)` command, such that the
configuration will be read on demand based on the filepath given during
initialization.

The changes will automatically be written once the instance goes out of scope, but
can be triggered manually as well.

The configuration file will be locked if you intend to change values preventing
other instances to write concurrently.

:note:
    The config is case-sensitive even when queried, hence section and option names
    must match perfectly.

:note:
    If used as a context manager, this will release the locked file.
z^\s*[#;]z\s*(?P<option>[^:=\s][^:=]*)z\s*(?P<vi>[:=])\s*z(?P<value>.*)$)Úadd_sectionrx   ry   rs   NÚfile_or_filesr   Ú	read_onlyÚmerge_includesrÒ   Úrepo)r   Nr0   c           	      óî  • [         R                  R                  U [        S9  U   U   U   [	        U S5      (       d  U R                  5       U l        Ub  Xl        OaUcM  U(       a;  [         Vs/ s H#  ofS:w  d  M
  [        [        [        U5      5      PM%     snU l        O[        S5      e[        U5      /U l        X l        SU l        SU l        X0l        XPl        SU l        U R'                  5         gs  snf )a  Initialize a configuration reader to read the given `file_or_files` and to
possibly allow changes to it by setting `read_only` False.

:param file_or_files:
    A file path or file object, or a sequence of possibly more than one of them.

:param read_only:
    If ``True``, the ConfigParser may only read the data, but not change it.
    If ``False``, only a single file path or file object may be given. We will
    write back the changes when they happen, or when the ConfigParser is
    released. This will not happen if other configuration files have been
    included.

:param merge_includes:
    If ``True``, we will read files mentioned in ``[include]`` sections and
    merge their contents into ours. This makes it impossible to write back an
    individual configuration file. Thus, if you want to modify a single
    configuration file, turn this off to leave the original dataset unaltered
    when reading it.

:param repo:
    Reference to repository to use if ``[includeIf]`` sections are found in
    configuration files.
)Ú	dict_typeÚ_proxiesNr(   z7No configuration level or configuration files specifiedF)ÚcpÚRawConfigParserr~   r¤   ÚhasattrÚ_dictrì   Ú_file_or_filesr)   rã   r   r   rá   Ú
_read_onlyrf   Ú_is_initializedÚ_merge_includesÚ_repoÚ_lockÚ_acquire_lock)r[   ræ   rç   rè   rÒ   ré   Úfs          r9   r~   ÚGitConfigParser.__init__A  sß   € ô@ 	×Ñ×#Ñ# D´DÐ#Ñ9ÙÙÙô �t˜Z×(Ñ(Ø ŸJ™J›LˆDŒMàÑ$ØdqÕàÑ#ÞåMZó+ÚMZÈÐcoÑ^oÓCœ¬Ô->ÀÓ(BÖCÉ]ñ+�DÕ'ô %Ð%^Ó_Ð_ä'6°|Ó'DÐ&E�Ô#à#ŒØˆŒØ$ˆÔØ-ÔØŒ
Ø.2ˆŒ
Ø×ÑÕùò+s   Á+	C2Á8C2c                 ó¸  • U R                   (       dÉ  U R                  (       d�  [        U R                  [        [
        R                  45      (       a  U R                  nOK[        U R                  [        [        [        45      (       a  [        S5      eU R                  R                  nU R                  U5      U l        U R                  R                  5         g g )NzVWrite-ConfigParsers can operate on a single file only, multiple files have been passed)rò   rö   Ú
isinstancerñ   rU   rÛ   r   ÚtupleÚlistr   rá   r-   Út_lockÚ_obtain_lock)r[   ræ   s     r9   r÷   ÚGitConfigParser._acquire_lock€  s�   € Ø��Ø—:—:Ü˜d×1Ñ1´C¼¿¹Ð3E×FÑFØ$(×$7Ñ$7‘MÜ × 3Ñ 3´e¼TÄ8Ð5L×MÑMÜ$Øpóð ð %)×$7Ñ$7×$<Ñ$<�Mð "Ÿ[™[¨Ó7�”
ð �J‰J×#Ñ#Õ%ð! rN   c                 ó$   • U R                  5         g)z4Write pending changes if required and release locks.N©r‚   rƒ   s    r9   r„   ÚGitConfigParser.__del__”  s   € ð 	�‰�rN   c                 ó&   • U R                  5         U $ r_   )r÷   rƒ   s    r9   r˜   ÚGitConfigParser.__enter__™  s   € Ø×ÑÔØˆrN   r\   c                 ó$   • U R                  5         g r_   r  )r[   r\   s     r9   rž   ÚGitConfigParser.__exit__�  s   € Ø�‰�rN   c                 ó²  • U R                   (       d0  U R                  (       a   U R                  R                  5       (       d  g U R                  5         U R                  b  U R                  R                  5         gg! [         a    [
        R                  SSS9   NI[         a     NTf = f! U R                  b  U R                  R                  5         f f = f)zîFlush changes and release the configuration write lock. This instance must
not be used anymore afterwards.

In Python 3, it's required to explicitly release locks and flush changes, as
``__del__`` is not called deterministically anymore.
Nz/Exception during destruction of GitConfigParserT)Úexc_info)	rç   rö   Ú	_has_lockrg   ÚIOErrorÚ_loggerÚerrorÚReferenceErrorÚ_release_lockrƒ   s    r9   r‚   ÚGitConfigParser.release   s¨   € ð �>�>˜dŸjŸj°·±×1EÑ1E×1GÑ1GØð	+Ø�J‰JŒLð �z‰zÑ%Ø—
‘
×(Ñ(Õ*ð &øô ó 	\Ü�M‰MÐKÐVZˆMÓ[Üó 	ñ ð		ûð �z‰zÑ%Ø—
‘
×(Ñ(Õ*ð &ús0   ÁA= Á=B)ÂB, Â	B)Â&B, Â(B)Â)B, Â,*CÚ	optionstrc                 ó   • U$ )z1Do not transform options in any way when writing.rO   )r[   r  s     r9   ÚoptionxformÚGitConfigParser.optionxform¹  s   € àÐrN   ÚfpÚfpnamec                 ó
	  • SnSnSnSnSnS[         S[         4S jnS[         S[        4S jn	S[         S[         4S	 jn
 UR                  5       R                  [        5      nU(       d  GOUS-   nUR                  5       S:X  d   U R                  R                  U5      (       a  Mh  UR                  SS5      S   R                  5       S:X  a  US   S;   a  Mš  U R                  R                  UR                  5       5      nU(       d›  U(       a”  UR                  S5      R                  5       nXÐR                  ;   a  U R                  U   nORU[        R                  :X  a  U R                  nO1U R!                  SU445      nX0R                  U'   SU R"                  U'   SnGOÕUc  [        R$                  " X%U5      eU(       Gd[  U R&                  R                  U5      nU(       GaÝ  UR                  SSS5      u  pNnU R)                  UR+                  5       5      nUS;   aa  SU;   a[  UR                  5       R-                  S5      (       d7  UR/                  S5      nUS:w  a   UUS-
     R1                  5       (       a  USU nUR                  5       n[3        U5      S:  d	  US   S:w  aÅ  Sn U	" U5      (       d  O¤UR                  5       nU(       d  USS nO‡US-   nUR                  [        5      nUR5                  S5      (       d  UR5                  S5      (       a5  USS nUR5                  S5      (       a  M  UR5                  S5      (       a  M5  USS U-   nS
nM²  U(       a  U
" U5      nOBUS   S:w  a  S
nU" USS 5      nO+[6        R8                  " SUSS 5      (       a  OU" USS 5      nUR;                  XO5        O³U R<                  R                  U5      (       d8  U(       d  [        R>                  " U5      nURA                  U[C        U5      5        GMâ  UR+                  5       nUR5                  S5      (       a  SnUSS nURE                  U5      nURG                  XOU" U5      -   5        GM<  U(       a  Ueg)a‡  Originally a direct copy of the Python 2.4 version of
:meth:`RawConfigParser._read <configparser.RawConfigParser._read>`, to ensure it
uses ordered dicts.

The ordering bug was fixed in Python 2.4, and dict itself keeps ordering since
Python 3.7. This has some other changes, especially that it ignores initial
whitespace, since git uses tabs. (Big comments are removed to be more compact.)
Nr   FÚvr0   c                 ó’   ^• U (       a  U R                  S5      (       a  U S S n SSSSSSS.m[        R                  " S	U4S
 jU 5      $ )NÚ\r¸   ÚÚ
ÚÚ	Ú")ÚbÚnÚrr8   r  r  z\\(.)c                 ód   >• TR                  U R                  S5      U R                  S5      5      $ )Né   r   )rr   Úgroup)ÚmatchÚescapess    €r9   rŠ   Ú>GitConfigParser._read.<locals>.string_decode.<locals>.<lambda>Ò  s!   ø€ °'·+±+¸e¿k¹kÈ!»nÈeÏkÉkÐZ[ËnÔ2]rN   )ÚendswithÚreÚsub)r  r'  s    @r9   Ústring_decodeÚ,GitConfigParser._read.<locals>.string_decodeÌ  sI   ø€ Þ�Q—Z‘Z ×%Ñ%Ø�c�r�F�ð ! t°$¸TÈÐSWÑXˆGÜ—6’6˜(Ô$]Ð_`ÓaÐarN   r§   c                 óˆ   • S=pU  H8  nU(       a  SnM  US:X  a  SnM  US:X  a	  U(       + nM'  US;   d  M/  U(       a  M8    g   U$ )NFr  Tr  ú#;rO   )r§   ÚquotedÚescapedÚchars       r9   Úis_line_continuationÚ3GitConfigParser._read.<locals>.is_line_continuationÖ  sK   € Ø$Ð$ˆFÛ�ÞØ#’GØ˜T“\Ø"’GØ˜S“[Ø!'œZ’FØ˜T•\¯&¨&Ù ñ ð ˆNrN   c                 óÒ  • / n/ nS=p4SSSSSS.nU  HÂ  nU(       a(  UR                  UR                  USU-   5      5        SnM2  UR                  5       (       a!  U(       d  U(       a  UR                  U5        Mh  US;   a	  U(       d    OOUR                  U5        UR	                  5         US:X  a  S	nM¢  US:X  a	  U(       + nM±  UR                  U5        MÄ     S
R                  U5      $ )NFr  r  r  r  r  )r   r!  r8   r  r  r/  TÚ )r¯   rr   ÚisspaceÚextendÚclearrÞ   )r§   ÚparsedÚ
whitespacer0  r1  r'  r2  s          r9   Úparse_valueÚ*GitConfigParser._read.<locals>.parse_valueã  sÏ   € Ø "ˆFØ$&ˆJØ$Ð$ˆFØ  t°$¸SÈÑMˆGÛ�ÞØ—M‘M '§+¡+¨d°D¸4±KÓ"@ÔAØ#�GÙØ—<‘<—>‘>®&ÞØ"×)Ñ)¨$Ô/ÙØ˜4“<®ÙØ—‘˜jÔ)Ø× Ñ Ô"Ø˜4“<Ø"’GØ˜S“[Ø!'œZ’Fà—M‘M $Ö'ñ% ð& —7‘7˜6“?Ð"rN   Tr$  r6  ÚremÚrRÚheaderrP   ÚoptionÚvi)Ú=Ú:Ú;r  r¸   r#   r  r  z(?:^|[^\\])(?:\\\\)*")$rU   ÚboolÚreadlineÚdecoder   ÚstripÚ
re_commentr&  ÚsplitÚlowerÚSECTCREr%  Ú	_sectionsrí   ÚDEFAULTSECTÚ	_defaultsrð   rì   ÚMissingSectionHeaderErrorÚOPTCREr  Úrstripr6   Úfindr7  Úlenr)  r*  Úsearchr°   ÚOPTVALUEONLYÚParsingErrorr¯   Úreprr¾   rÂ   )r[   r  r  ÚcursectÚoptnameÚlinenoÚis_multi_lineÚer,  r3  r<  ÚlineÚmoÚsectnamerB  ÚoptvalÚposÚ	continuedÚcontinuationÚjoineds                       r9   Ú_readÚGitConfigParser._read½  s	  € ð ˆØˆØˆØˆØˆð	bœSð 	b¤Sô 	bð	¬ð 	´ô 	ð	#œsð 	#¤sô 	#ð4 à—;‘;“=×'Ñ'¬Ó/ˆDÞÙØ˜a‘ZˆFà�z‰z‹|˜rÓ! T§_¡_×%:Ñ%:¸4×%@Ñ%@ÙØ�z‰z˜$ Ó" 1Ñ%×+Ñ+Ó-°Ó6¸4À¹7Àd»?áð —‘×#Ñ# D§J¡J£LÓ1ˆBÞ ¦RØ "§¡¨Ó 2× 8Ñ 8Ó :�ØŸ~™~Ó-Ø"Ÿn™n¨XÑ6‘GØ¤§¡Ó/Ø"Ÿn™n‘Gà"Ÿj™j¨:°xÐ*@Ð)BÓC�GØ/6—N‘N 8Ñ,Ø.2�D—M‘M (Ñ+à’à‘Ü×2Ò2°6À4ÓHÐHç"Ø—[‘[×&Ñ& tÓ,�ßà*,¯(©(°8¸TÀ7Ó*KÑ'�G Ø"×.Ñ.¨w¯~©~Ó/?Ó@�Gà˜ZÓ'¨C°6«MÀ&Ç,Á,Ã.×B[ÑB[Ð\_×B`ÑB`Ø$Ÿk™k¨#Ó.˜Ø "›9¨°°a±©×)@Ñ)@×)BÑ)BØ%+¨D¨S \˜FØ#Ÿ\™\›^�Fä˜6“{ Q“¨&°©)°sÓ*:ð %*˜	Ø"Ù#7¸×#?Ñ#?Ø %Ø+-¯;©;«=˜LÞ#/à)/°°¨ Ø %Ø%+¨a¡Z˜FØ%1×%8Ñ%8¼Ó%@˜FØ"(§/¡/°$×"7Ñ"7¸6¿?¹?È4×;PÑ;PØ)/°°¨ ð #)§/¡/°$×"7Ó"7¸6¿?¹?È4×;PÓ;Pà%+¨C¨R [°6Ñ%9˜FØ(,˜Iñ #ö %Ù%0°Ó%8˜FøØ ™ sÓ*à(,˜Ù!.¨v°a°b¨zÓ!:™ÜŸšÐ#;¸VÀAÀb¸\×JÑJàñ "/¨v°a¸¨|Ó!<˜ð —K‘K Õ0ð  ×,Ñ,×2Ñ2°4×8Ñ8Þ Ü "§¢°Ó 7˜AØŸ™ ¬¨d«Ô4Úà—{‘{“}�Ø—=‘= ×%Ñ%Ø$)�MØ  ˜9�Dà Ÿ™¨Ó1�Ø—‘ ±-ÀÓ2EÑ)EÔFòA öJ ØˆGð rN   c                 óZ   • U R                   =(       a    [        U R                  5       5      $ r_   )rô   rU  Ú_included_pathsrƒ   s    r9   Ú_has_includesÚGitConfigParser._has_includese  s!   € Ø×#Ñ#×C¬¨D×,@Ñ,@Ó,BÓ(CÐCrN   c                 ó~  ^ ^• S[         S[        [        [         [         4      4U 4S jjn/ nT R                  5        GHi  nUS:X  a
  X!" U5      -  n[        R                  U5      nUb  T R                  c  M;  UR                  S5      nUR                  S5      R                  5       mUS;   GaJ  [        R                  " T5      mT R                  R                  (       a*  [        R                  " T R                  R                  5      OSn[        R                  S	:X  a  U(       a  UR!                  S
S5      OSn[        R"                  " T5      u  pxU(       d  [%        U4S jS 5       5      (       d  ST-   mTR'                  S5      (       a  TS-  mUR'                  S5      (       a  [(        R*                  " SS T5      mU(       a,  [,        R.                  " UT5      (       a  X!" U5      -  nGM¶  GM¹  GM¼  US:X  aM   T R                  R0                  R2                  n	[,        R.                  " U	T5      (       a  X!" U5      -  nGM  GM  US:X  d  GM  T R                  R6                   H7  n
[,        R.                  " U
R8                  T5      (       d  M+  X!" U5      -  n  GMg     GMl     U$ ! [4         a     GM~  f = f)z‡List all paths that must be included to configuration.

:return:
    The list of paths, where each path is a tuple of (option, value).
r|   r0   c                 ó    >• TR                   U    R                  5        VVVs/ s H  u  pUS:w  d  M  U  H  nX4PM     M     snnn$ s  snnnf )zFReturn all (key, value) pairs for a section, including duplicate keys.rP   )rN  rÐ   )r|   r¦   r²   r§   r[   s       €r9   Ú
_all_itemsÚ3GitConfigParser._included_paths.<locals>._all_itemso  s^   ø€ ð $(§>¡>°'Ñ#:×#DÑ#DÔ#Fõâ#F‘K�CØ˜*Ñ$ó ô $�Eð “ñ $ñ Ù#Fóð ùô s
   £A	³A	ÚincludeNr$  r#   )Úgitdirzgitdir/irÔ   r  Ú/c              3   óF   >#   • U  H  nTR                  U5      v •  M     g 7fr_   r5   )r7   Úsr§   s     €r9   r:   Ú2GitConfigParser._included_paths.<locals>.<genexpr>Œ  s   øé € Ð(RÂkÀ¨×)9Ñ)9¸!×)<Ð)<Âkùs   ƒ!)z./rs  z**/z**z/iz[a-zA-Z]c                 ó†   • SU R                  5       R                  5       < U R                  5       R                  5       < S3$ )NÚ[Ú])r%  rL  Úupper)Úms    r9   rŠ   Ú1GitConfigParser._included_paths.<locals>.<lambda>•  s-   €  A a§g¡g£i§o¡oÓ&7Ñ%:¸1¿7¹7»9¿?¹?Ó;LÑ:OÈqÑ"QrN   Úonbranchzhasconfig:remote.*.url)rU   r   r   ÚsectionsÚCONDITIONAL_INCLUDE_REGEXPrV  rõ   r%  rI  rÝ   rà   Úgit_dirrÛ   ÚfspathrÙ   rÚ   ÚreplaceÚ
splitdriveÚanyr)  r*  r+  ÚfnmatchÚfnmatchcaseÚactive_branchr-   Ú	TypeErrorÚremotesÚurl)r[   ro  Úpathsr|   r&  Úkeywordr€  ÚdriveÚ_tailÚbranch_nameÚremoter§   s   `          @r9   rj  ÚGitConfigParser._included_pathsh  s?  ù€ ð	¤ð 	¬¬U´3¼°8©_Ñ(=÷ 	ð ˆà—}‘}—ˆGØ˜)Ó#Ø˜ GÓ,Ñ,�ä.×5Ñ5°gÓ>ˆEØ‰} §
¡
Ñ 2Ùà—k‘k !“nˆGØ—K‘K “N×(Ñ(Ó*ˆEàÐ0Ô0ÜŸš uÓ-�Ø;?¿:¹:×;M×;Mœ"Ÿ)š) D§J¡J×$6Ñ$6Ô7ÐSW�Ü—<‘< 7Ó*Þ<C˜gŸo™o¨d°CÔ8È�Gä"Ÿ~š~¨eÓ4‘�Þ¤SÔ(RÁkÓ(R×%RÑ%RØ! E™M�EØ—>‘> #×&Ñ&Ø˜T‘M�Eð ×#Ñ# D×)Ñ)ÜŸFšFØ#ÙQØó�Eö
 œw×2Ò2°7¸E×BÑBØ˜Z¨Ó0Ñ0“Eò  C’7ð ˜JÓ&ðØ"&§*¡*×":Ñ":×"?Ñ"?�Kô
 ×&Ò& {°E×:Ñ:Ø˜Z¨Ó0Ñ0“Eò ;àÐ4Ö4Ø"Ÿj™j×0Ô0�FÜ×*Ò*¨6¯:©:°u×=Ó=Ø ¨GÓ!4Ñ4˜Ûô 1ñW 'ð^ ˆøô !ó ãðús   È  J-Ê-
J<Ê;J<c                 óD  • U R                   (       a  gSU l         S/n[        U R                  [        [        R
                  45      (       a  U R                  /nOM[        U R                  [        [        [        45      (       d  U R                  /nO[        U R                  5      nU Vs/ s H@  n[        U[        [        R
                  45      (       a  [        R                  " U5      OUPMB     nn[        U5      nSnU(       Gaá  UR                  S5      nSn[        US5      (       a3  [        [        [            U5      nU R#                  XUR$                  5        O3 ['        US5       nSnU R#                  XwR$                  5        SSS5        U R+                  5       (       Ga7  U R-                  5        GH"  u  p‰U	R/                  S5      (       a  [        R0                  " U	5      n	[        R2                  " U	5      (       df  U(       d  MV  [        [
        U5      n[        R2                  " U5      (       d   S	5       e[        R4                  " [        R6                  " U5      U	5      n	[        R8                  " U	5      n	X“;   d*  [        R:                  " U	[        R<                  5      (       d  Mú  UR?                  U	5        URA                  SU	5        US
-  nGM%     U(       a  GMá  US:X  a  SU l!        ggs  snf ! , (       d  f       GNz= f! [(         a     GM  f = f)zÉRead the data stored in the files we have been initialized with.

This will ignore files that cannot be read, possibly leaving an empty
configuration.

:raise IOError:
    If a file cannot be handled.
NTr6  r   FÚseekÚrbr×   z9Need absolute paths to be sure our cycle checks will workr$  )"ró   rû   rñ   rU   rÛ   r   rü   rý   r   rÝ   Úabspathrs   Úpoprï   r   r   Úbytesrg  r-   Úopenr  rk  rj  r6   rà   ÚisabsrÞ   Údirnamerß   ÚaccessÚR_OKr°   Úinsertrô   )
r[   Úfiles_to_readÚpathÚseenÚnum_read_include_filesÚ	file_pathÚfile_okr  r4   Úinclude_paths
             r9   r`   ÚGitConfigParser.read«  sp  € ð ××ØØ#ˆÔà46°4ˆÜ�d×)Ñ)¬C´·±Ð+=×>Ñ>à!×0Ñ0Ð1‰MÜ˜D×/Ñ/´%¼¼xÐ1H×IÑIà!×0Ñ0Ð1‰Mä  ×!4Ñ!4Ó5ˆMñ jwÓwÒivÐae¬j¸ÄÄRÇ[Á[Ð?Q×.RÑ.RœŸš TÔ*ÐX\Ò\ÑivˆÐwä�=Ó!ˆØ!"ÐßØ%×)Ñ)¨!Ó,ˆIØˆGä�y &×)Ñ)ô !¤¤E¡¨IÓ6�	Ø—
‘
˜9§n¡nÕ5ðÜ˜i¨Ô.°"Ø"&˜ØŸ
™
 2§w¡wÔ/÷ /ð ×!Ñ!×#Ò#Ø'+×';Ñ';×'=‘O�AØ#×.Ñ.¨s×3Ñ3Ü'*§~¢~°lÓ'C˜ÜŸ9š9 \×2Ñ2Þ&Ù$ä$(¬°9Ó$=˜	Ü"Ÿyšy¨×3Ñ3ÐpÐ5pÓpÐ3Ü'*§x¢x´·²¸IÓ0FÈÓ'U˜ä#&§<¢<°Ó#=�LØ#Ó+´2·9²9¸\Ì2Ï7É7×3SÑ3SÙ Ø—H‘H˜\Ô*à!×(Ñ(¨¨LÔ9Ø*¨aÑ/Ó*ñ# (>÷) ‰mðX " QÓ&Ø#(ˆDÕ ð 'ùòa x÷ /Ö.ûô ó Ûðús7   Â+AK9Å!L Å-K>ÆL Ë>
LÌL ÌL Ì
LÌLc                 óð   ^ ^• S[         S[        SS4UU 4S jjnT R                  (       a!  U" [        R                  T R                  5        T R
                  R                  5        H  u  p4U" X45        M     g)zXWrite an .ini-format representation of the configuration state in
git compatible format.r-   Úsection_dictr0   Nc           	      óh  >^• TR                  SU -  R                  [        5      5        UR                  5        Hõ  u  p#US:X  a  M  U Hâ  nTR	                  U5      m[        U4S jS 5       5      (       d0  TS S R                  5       (       d  TSS  R                  5       (       aW  TR                  SS5      R                  S	S
5      mSTR                  SS5      R                  SS5      R                  SS5      -  mTR                  SU< ST< S3R                  [        5      5        Mä     M÷     g )Nz[%s]
rP   c              3   ó,   >#   • U  H	  oT;   v •  M     g 7fr_   rO   )r7   r2  r§   s     €r9   r:   Ú@GitConfigParser._write.<locals>.write_section.<locals>.<genexpr>  s   øé € ÐC²]¨T 5ž=²]ùs   ƒz
	\"#;r$  r¸   r  z\\r  z\"z"%s\
"r  z\nr  z\tr  z\bz = )rg   Úencoder   rÐ   Ú_value_to_stringr„  r7  r‚  )r-   r§  r¦   r²   r  r§   r  r[   s        @€€r9   Úwrite_sectionÚ-GitConfigParser._write.<locals>.write_sectionú  s  ù€ Ø�H‰H�h ‘o×-Ñ-¬fÓ5Ô6ð  ,×5Ñ5Ö7‘�Ø˜*Ó$Ùã�AØ ×1Ñ1°!Ó4�EÜÔC±]ÓC×CÑCÀuÈRÈaÀy×GXÑGX×GZÑGZÐ^cÐdfÐdgÐ^h×^pÑ^p×^rÑ^rØ %§¡¨d°FÓ ;× CÑ CÀCÈÓ O˜Ø *¨U¯]©]¸4ÀÓ-G×-OÑ-OÐPTÐV[Ó-\×-dÑ-dÐeiÐkpÓ-qÑ q˜Ø—H’H«s³EÐ:×BÑBÄ6ÓJÖKó  ò	  8rN   )rU   r¤   rP  rí   rO  rN  rÍ   )r[   r  r­  r-   r§   s   ``   r9   Ú_writeÚGitConfigParser._writeö  se   ù€ ð	L¤ð 	L´4ð 	L¸D÷ 	Lð 	Lð& �>�>Ùœ"Ÿ.™.¨$¯.©.Ô9ð  Ÿ>™>×/Ñ/Ö1‰KˆDÙ˜$Ö&ò 2rN   Úsection_namec                 ój   >• [         TU ]  U5       VVs/ s H  u  p#US:w  d  M  X#4PM     snn$ s  snnf )zK:return: list((option, value), ...) pairs of all items in the given sectionrP   )rA   rÍ   )r[   r±  rÌ   r  rL   s       €r9   rÍ   ÚGitConfigParser.items  s2   ø€ ä#(¡7¡=°Ô#>ÔRÒ#>™4˜1À!ÀzÁ/“�“Ñ#>ÒRÐRùÓRs   ”/¤/c                 ó  • [        U R                  5      nU R                  U   R                  5        HC  u  p4US:X  a  M  X2;   a  UR	                  U5      U:X  a  M)  U H  nUR                  X55        M     ME     UR                  5       $ )zQ:return: list((option, [values...]), ...) pairs of all items in the given sectionrP   )r¤   rP  rN  rÐ   rÈ   r°   )r[   r±  ÚrvrÌ   Úvsr  s         r9   rÐ   ÚGitConfigParser.items_all  sr   € ä�$—.‘.Ó!ˆà—^‘^ LÑ1×;Ñ;Ö=‰EˆAØ�J‹Ùà‹w˜2Ÿ9™9 Q›<¨2Ó-Ùã�Ø—‘�q–ó ñ >ð �|‰|‹~ÐrN   c                 óŒ  • U R                  S5        U R                  (       d  g[        U R                  [        [
        45      (       a!  [        S[        U R                  5      -  5      eU R                  5       (       a  [        R                  S5        gU R                  /nU R                  R                  5        H  u  p#UR                  U5        M     U Hb  nUR                  5        HK  u  pVUS:w  d  M  U H8  nSU R!                  U5      ;   d  SU R!                  U5      ;   d  M/  [#        S5      e   MM     Md     U R                  n[        U[$        [&        R(                  [*        45      n	U	(       a'  U R,                  b  U R,                  R/                  5         [1        US	5      (       d7  [3        [(        U5      n[5        US
5       n
U R7                  U
5        SSS5        g[3        SU5      nUR9                  S5        [1        US5      (       a  UR;                  5         U R7                  U5        g! , (       d  f       g= f)zŸWrite changes to our file, if there are changes at all.

:raise IOError:
    If this is a read-only writer instance or if we could not obtain a file
    lock.
rg   NzRCannot write back if there is not exactly a single file to write to, have %i fileszsSkipping write-back of configuration file as include files were merged in.Set merge_includes=False to prevent this.rP   r  Ú z,Git config values must not contain CR or NULr“  Úwbr   r   Útruncate)Ú_assure_writablerf   rû   rñ   rý   rü   ÚAssertionErrorrU  rk  r  ÚdebugrP  rN  rÍ   r¯   rÐ   r¬  rá   rU   rÛ   r   r   rö   rÿ   rï   r   r˜  r¯  r“  r»  )r[   r~  r4   Ústored_sectionr|   r¦   r²   Ú	raw_valuer  Úis_file_lockÚfp_opens              r9   rg   ÚGitConfigParser.write(  sÒ  € ð 	×Ñ˜gÔ&Ø�{�{Øä�d×)Ñ)¬D´%¨=×9Ñ9Ü ØdÜ�d×)Ñ)Ó*ñ+óð ð ×Ñ×ÑÜ�M‰Mð>ôð ð !%§¡Ð/ˆð
 "&§¡×!5Ñ!5Ö!7ÑˆAØ�O‰O˜NÖ+ñ "8ãˆGØ&×0Ñ0Ö2‘�Ø˜*Õ$Û%+˜	Ø 4×#8Ñ#8¸Ó#CÓCÀvÐQU×QfÑQfÐgpÓQqÕGqÜ",Ð-[Ó"\Ð\ó &,ó  3ñ  ð × Ñ ˆô " "¤s¬B¯K©K¼Ð&@ÓAˆÞ˜DŸJ™JÑ2Ø�J‰J×#Ñ#Ô%ä�r˜6×"Ñ"Ü”h Ó#ˆBÜ�b˜$” 7Ø—‘˜GÔ$÷  �ô �i Ó$ˆBØ�G‰G�AŒJä�r˜:×&Ñ&Ø—‘”Ø�K‰K˜�O÷  •ús   Ç
H5È5
IrH   c                 óL   • U R                   (       a  [        SU < SU< 35      eg )Nz#Cannot execute non-constant method Ú.)rç   r  )r[   rH   s     r9   r¼  Ú GitConfigParser._assure_writabled  s   € Ø�>�>ÝËÊkÐZÓ[Ð[ð rN   r|   úcp._SectionNamec                 óF   >• U R                  US5        [        TU ]	  U5      $ )z)Assures added options will stay in order.r|   )Ú_assure_config_name_saferA   rå   )r[   r|   rL   s     €r9   rå   ÚGitConfigParser.add_sectionh  s#   ø€ à×%Ñ% g¨yÔ9Ü‰wÑ" 7Ó+Ð+rN   c                 ó   • U R                   $ )zD:return: ``True`` if this instance may change the configuration file)rò   rƒ   s    r9   rç   ÚGitConfigParser.read_onlym  s   € ð �‰ÐrN   rA  rÄ   c                 ót   •  U R                  X5      nU R                  U5      $ ! [         a	    Ub  Us $ e f = f)a½  Get an option's value.

If multiple values are specified for this option in the section, the last one
specified is returned.

:param default:
    If not ``None``, the given default value will be returned in case the option
    did not exist.

:return:
    A properly typed value, either int, float or string

:raise TypeError:
    In case the value could not be understood.
    Otherwise the exceptions known to the ConfigParser will be raised.
)rr   Ú	ExceptionÚ_string_to_value)r[   r|   rA  rÄ   Úvaluestrs        r9   rp   ÚGitConfigParser.get_values  sG   € ð,	Ø—x‘x Ó0ˆHð ×$Ñ$ XÓ.Ð.øô ó 	ØÑ"Ø’Øð	ús   ‚$ ¤7µ7c                 óÚ   •  U R                  5         U R                  U   R                  U5      nU Vs/ s H  oPR	                  U5      PM     sn$ ! [         a
    Ub  U/s $ e f = fs  snf )aÇ  Get an option's values.

If multiple values are specified for this option in the section, all are
returned.

:param default:
    If not ``None``, a list containing the given default value will be returned
    in case the option did not exist.

:return:
    A list of properly typed values, either int, float or string

:raise TypeError:
    In case the value could not be understood.
    Otherwise the exceptions known to the ConfigParser will be raised.
)r~  rN  rÈ   rÎ  rÏ  )r[   r|   rA  rÄ   ÚlstrÐ  s         r9   Ú
get_valuesÚGitConfigParser.get_values’  sr   € ð,	Ø�M‰MŒOØ—.‘. Ñ)×0Ñ0°Ó8ˆCñ ADÓDÂ°H×%Ñ% hÖ/ÁÑDÐDøô ó 	ØÑ"Ø�yÒ Øð	üò
 Es   ‚.A ´A(ÁA%Á#A%rÐ  c                 ó  • [         [        4nU H  n U" U5      nU[        U5      :w  a  M  Us  $    UR	                  5       nUS:X  a  gUS:X  a  g[        U[        5      (       d  [        SU5      eU$ ! [        [        4 a     Mw  f = f)NÚfalseFÚtrueTz=Invalid value type: only int, long, float and str are allowed)ÚintÚfloatrá   rˆ  rL  rû   rU   )r[   rÐ  ÚtypesÚnumtypeÚvalÚvls         r9   rÏ  Ú GitConfigParser._string_to_value²  sš   € Ü”e�ˆÛˆGðÙ˜hÓ'�àœ% ›/Ó)ÙØ’
ñ ð �^‰^ÓˆØ�‹=ØØ�‹<Øä˜(¤C×(Ñ(ÜØOØóð ð
 ˆøô# ¤	Ð*ó Úðús   “A3¬A3Á3BÂBr§   c                 ón   • [        U[        [        [        45      (       a  [	        U5      $ [        U5      $ r_   )rû   rÙ  rÚ  rF  rU   r	   )r[   r§   s     r9   r¬  Ú GitConfigParser._value_to_stringÎ  s+   € Ü�eœc¤5¬$Ð/×0Ñ0Ü�u“:ÐÜ˜%Ó Ð rN   c                 ór   • U R                  U5      n[        R                  U5      (       a  [        S5      eU$ )Nz1Git config values must not contain CR, LF, or NUL)r¬  ÚUNSAFE_CONFIG_CHARS_RErV  rá   )r[   r§   Ú	value_strs      r9   Ú_value_to_string_safeÚ%GitConfigParser._value_to_string_safeÓ  s5   € Ø×)Ñ)¨%Ó0ˆ	Ü!×(Ñ(¨×3Ñ3ÜÐPÓQÐQØÐrN   r-   Úlabelc                 ó\  • [        U[        5      (       a(  [        R                  U5      (       a  [	        SU-  5      eUS:X  a:  [        U[        5      (       a%  [
        R                  U5      (       d  [	        S5      eUS:X  a©  [        U[        5      (       a“  SnSn[        U5       Hm  u  pVU(       a  SnM  U(       a
  US:X  a  SnM!  US:X  a,  U(       d  US	:X  d  XS
-
     S;  a  [	        S5      eU(       + nMS  US:X  d  M[  U(       a  Md  [	        S5      e   U(       a  [	        S5      eg g g )Nz3Git config %s names must not contain CR, LF, or NULrA  zJGit config option names may contain only letters, digits, '-', '_', or '.'r|   Fr  Tr  r   r$  z 	z>Git config quoted subsection names must begin after whitespacery  zEGit config section names must not contain an unquoted closing bracketz?Git config section names must not contain an unterminated quote)rû   rU   rã  rV  rá   ÚVALID_CONFIG_OPTION_NAME_REÚ	fullmatchÚ	enumerate)r[   r-   rç  Ú	in_quotesr1  Úindexr2  s          r9   rÉ  Ú(GitConfigParser._assure_config_name_safeÙ  s  € Ü�dœC× Ñ Ô%;×%BÑ%BÀ4×%HÑ%HÜÐRÐUZÑZÓ[Ð[Ø�HÓ¤¨D´#×!6Ñ!6Ô?Z×?dÑ?dÐei×?jÑ?jÜÐiÓjÐjØ�IÓ¤*¨T´3×"7Ñ"7ØˆIØˆGÜ(¨ž‘�ÞØ#’GÞ 4¨4£<Ø"’GØ˜S“[Þ$¨%°1«*¸ÀQ¹Y¹ÈuÓ8TÜ(Ð)iÓjÐjØ$-¤’IØ˜S•[¯¨Ü$Ð%lÓmÐmñ  /ö Ü Ð!bÓcÐcð ð #8ÐrN   c                 ó”   >• U R                  US5        U R                  US5        Ub  U R                  U5      n[        TU ]  XU5      $ )Nr|   rA  )rÉ  rå  rA   rs   )r[   r|   rA  r§   rL   s       €r9   rs   ÚGitConfigParser.setï  sL   ø€ ð 	×%Ñ% g¨yÔ9Ø×%Ñ% f¨hÔ7ØÑØ×.Ñ.¨uÓ5ˆEÜ‰w‰{˜7¨EÓ2Ð2rN   c                 óà   >• U R                  US5        U R                  US5        U R                  U5      nU R                  U5      (       d  U R                  U5        [        TU ]  XU5        U $ )a·  Set the given option in section to the given value.

This will create the section if required, and will not throw as opposed to the
default ConfigParser ``set`` method.

:param section:
    Name of the section in which the option resides or should reside.

:param option:
    Name of the options whose value to set.

:param value:
    Value to set the option to. It must be a string or convertible to a string.

:return:
    This instance
r|   rA  )rÉ  rå  Úhas_sectionrå   rA   rs   )r[   r|   rA  r§   rä  rL   s        €r9   rq   ÚGitConfigParser.set_valueý  sg   ø€ ð( 	×%Ñ% g¨yÔ9Ø×%Ñ% f¨hÔ7Ø×.Ñ.¨uÓ5ˆ	Ø×Ñ ×(Ñ(Ø×Ñ˜WÔ%Ü‰‰�G YÔ/ØˆrN   c                 óú   • U R                  US5        U R                  US5        U R                  U5      nU R                  U5      (       d  U R                  U5        U R                  U   R                  X$5        U $ )a*  Add a value for the given option in section.

This will create the section if required, and will not throw as opposed to the
default ConfigParser ``set`` method. The value becomes the new value of the
option as returned by :meth:`get_value`, and appends to the list of values
returned by :meth:`get_values`.

:param section:
    Name of the section in which the option resides or should reside.

:param option:
    Name of the option.

:param value:
    Value to add to option. It must be a string or convertible to a string.

:return:
    This instance
r|   rA  )rÉ  rå  rò  rå   rN  r°   )r[   r|   rA  r§   rä  s        r9   Ú	add_valueÚGitConfigParser.add_value  so   € ð, 	×%Ñ% g¨yÔ9Ø×%Ñ% f¨hÔ7Ø×.Ñ.¨uÓ5ˆ	Ø×Ñ ×(Ñ(Ø×Ñ˜WÔ%Ø�‰�wÑ×#Ñ# FÔ6ØˆrN   Únew_namec                 óp  >• U R                  U5      (       d  [        SU-  5      eU R                  US5        U R                  U5      (       a  [        SU-  5      e[        TU ]  U5        U R
                  U   nU R                  U5       H  u  pEUR                  XE5        M     U R                  U5        U $ )z´Rename the given section to `new_name`.

:raise ValueError:
    If:

    * `section` doesn't exist.
    * A section with `new_name` does already exist.

:return:
    This instance
z!Source section '%s' doesn't existr|   z'Destination section '%s' already exists)	rò  rá   rÉ  rA   rå   rN  rÐ   r´   rx   )r[   r|   r÷  Únew_sectionrÌ   r¶  rL   s         €r9   Úrename_sectionÚGitConfigParser.rename_section7  s¬   ø€ ð ×Ñ ×(Ñ(ÜÐ@À7ÑJÓKÐKØ×%Ñ% h°	Ô:Ø×Ñ˜H×%Ñ%ÜÐFÈÑQÓRÐRä‰Ñ˜HÔ%Ø—n‘n XÑ.ˆØ—^‘^ GÖ,‰EˆAØ×Ñ˜qÖ%ñ -ð 	×Ñ˜GÔ$ØˆrN   )rf   rñ   ró   rö   rô   rì   rò   rõ   )NTTNNr    )r0   r   )r|   rÇ  r0   Nr_   )=rP   rQ   rR   rS   rT   r
   rþ   r*  ÚcompilerJ  Úoptvalueonly_sourcerW  rR  r2   r   r   r   rF  r   r~   r÷   r„   r˜   r   rž   r‚   rU   r  r   r   r—  rg  rÙ  rk  r   r   rj  r`   r¯  rÍ   rÐ   r?   rg   r¼  rå   r¢   rç   rÚ  rp   rÔ  rÏ  r¬  rå  rÉ  r@   rs   rq   rõ  rú  rV   rW   rX   s   @r9   r   r     sk  ø† ñð* €Fðð —’˜KÓ(€Jð :Ðà—:’:Ð1Ó2€Là�ZŠZÐ+Ð.CÑCÐFWÑWÓX€FààRÐðð
 aeØØ#Ø7;Ø$(ñ=à˜T 8¨Y¸ÀÀxÐQZÐGZÑA[Ñ8\Ð\Ñ]ð=ð ð=ð ð	=ð
 Ð-¨tÐ3Ñ4ð=ð �LÑ!ð=ð 
õ=ô~&ô(ô
ð˜cð  dô ô+ð2 Sð ¨Sô ðf˜˜n¨b°©iÐ7Ñ8ð fÀ#ð fÈ$ô fðPD˜u T¨3 YÑ/ô DðA  e¨C°¨H¡oÑ!6ô AôFI)ðV'˜ð ' ô 'ð<S #ð S¨$¨u°S¸#°X©Ñ*?÷ Sð cð ¨d°5¸¸dÀ3¹i¸Ñ3HÑ.Iô ð  ó9ó ð9ðv\¨Cð \°Dô \÷,ð
 ð˜4ó ó ðð 7;ñ	/àð/ð ð/ð �s˜E 3¨¨dÐ2Ñ3ð	/ð
 
ˆs�E˜3 Ð$Ñ	%õ/ðF 7;ñ	EàðEð ðEð �s˜E 3¨¨dÐ2Ñ3ð	Eð
 
ˆe�C˜  TÐ)Ñ*Ñ	+õEð@¨ð °°s¸EÀ3ÈÐ7LÑ1Mô ð8! e¨C°¸¸UÀDÐ,HÑ&Ið !Ècô !ð
¨5°°e¸SÀ%ÈÐ1MÑ+Nð ÐSVô ðdÐ->ð dÀsð dÈtô dð, Ø ð
 <@ñ	
3àð
3ð ð
3ð �S˜%  e¨T°4Ð7Ñ8ð	
3ð
 
÷
3ó !ó ð
3ð Ø ð ð ¨cð ¸%ÀÀUÈCÐQVÐX\Ð@\Ñ:]ð Ðbsö ó !ó ðð4 Ø ð ð ¨cð ¸%ÀÀUÈCÐQVÐX\Ð@\Ñ:]ð Ðbsó ó !ó ðð8 cð °Sð Ð=N÷ õ rN   )Ú	metaclass)KrT   Ú__all__ÚabcÚconfigparserrí   r…  Ú	functoolsr   r<   Úior   r   ÚloggingrÛ   Úos.pathrŸ  rÝ   r*  rÙ   Ú
git.compatr   r	   Úgit.utilr
   Útypingr   r   r   r   r   r   r   r   r   r   r   r   Ú	git.typesr   r   r   r   r   r   Úgit.repo.baser   r   rU   r—  rÙ  rÚ  rF  r    Úversion_infoÚcollectionsr$   ÚOrderedDict_OMDÚ	getLoggerrP   r  r)   Ú__annotations__rü  r  rã  ré  ÚABCMetar+   r?   r@   r   r¤   rã   rî   r   rO   rN   r9   Ú<module>r     s»  ðò :àÐ1Ð
2€ã 
Û Û Ý Û ß %Û Û 	Ý Û 	Û 
ç )Ý ÷÷ ÷ ó ÷ VÕ UæÝå"áÐ)Ð1BÑC€Ù�m S¨%°°e¸TÓB€à×Ñ�B�QÐ˜)Ó#å'à!�Oå"à! # t¨KÑ'8Ð"8Ñ9€Oð ×
Ò
˜HÓ
%€à"L€ÐÓ LØ 6àŸZšZÐ(wÓxÐ ðð
 Ÿš MÓ2Ð Ø Ià ŸjšjÐ)=Ó>Ð Ø Rô˜Ÿ™ô ð>
�x  R Ñ(ð 
¨X°c¸2°gÑ->ô 
ð°¸¸b¸Ñ0Að ÀhÈsÐTVÈwÑFWô ô$=J˜ Ñ/ô =Jô@*3ˆ?ô *3ðZ
Ð"3ð 
¸ô 
ô0}�b×(Ñ(Ð4Eó }rN   