Ë
   b�WJêtâGã            
       ó¬   — d Z ddlmZmZ ddlZddlZddlZddlZ ej                  dd«      Z	e
Zd„ Z
d„ Zdd	gZd
dddddddej                  ef
d„Zd„ Zy)z¥Simplify your python project versioning.

In-depth docs online: https://vcversioner.readthedocs.org/en/latest/
Code online: https://github.com/habnabit/vcversioner

é    )Úprint_functionÚunicode_literalsNÚVersionzversion commits shac                  ó"   — t        dg| ¢­i |¤Ž y )Nzvcversioner:)Ú_print)ÚaÚkws     úŸ/home/sim/yocto/scarthgap/build/tmp/work/x86_64-linux/python3-vcversioner-native/2.16.0.0/recipe-sysroot-native/usr/lib/python3.12/site-packages/vcversioner.pyÚprintr   "   s   € Ü
ˆ>Ð$˜AÒ$ Ó$ó    c                 óB   — | j                  dt        j                  «      S )z/Translate ``/``s into the right path separator.Ú/)ÚreplaceÚosÚsep)Úps    r
   Ú	_fix_pathr   &   s   € à�9‰9�Sœ"Ÿ&™&Ó!Ð!r   )ú%(root)s/.git)Úgitz	--git-dirr   Údescribez--tagsz--long)z%(root)s/.hg)ÚhgÚlogz-Rz%(root)sz-rÚ.z
--templatez.{latesttag}-{latesttagdistance}-hg{node|short}Tz%(pwd)sz%(root)s/version.txt© Úvc
           
      ó¦  ‡‡— dt        j                  «       iŠ|‰z  ‰d<   ˆfd„}
|� |
|«      }|�t        j                  dt        «       |}|€7t
        D ].  \  }}t         j                  j                   |
|«      «      sŒ,|} n d}g Š|�”|D �cg c]
  } |
|«      ‘Œ }}	  ||t        j                  t        j                  ¬«      }|j                  «       \  }}|j                  «       j                  «       }|j                  «       j                  «       Šd}|›d�}nd	‰z  }ˆfd
„}|sª|€ t        |›d�«        |«        t!        d«      ‚t         j                  j                  |«      s.t        |›d|›d�«       t        d«        |«        t!        d«      ‚ |	|d«      5 }|j#                  «       j                  «       }ddd«       t%        |«      }	 |j'                  dd«      \  }}}|j+                  |«      r|t-        |«      d }|�# |	|d«      5 }|j/                  |«       ddd«       |j+                  d«      r|€d}|rt1        t3        |«      dz
  «      }|dk(  s| s|}n|›d|›�}|D ]e  } |	|d«      5 }|j/                  dj5                  t%        |«      j7                  d«      t%        |«      j7                  d«      «      «       ddd«       Œg t9        |||«      S c c}w # t        $ r Y �ŒÞw xY w# 1 sw Y   �Œ;xY w# t(        $ r$ t        |›d›d�«        |«        t!        d«      ‚w xY w# 1 sw Y   �ŒxY w# 1 sw Y   ŒÝxY w)a³  Find an appropriate version number from version control.

    It's much more convenient to be able to use your version control system's
    tagging mechanism to derive a version number than to have to duplicate that
    information all over the place.

    The default behavior is to write out a ``version.txt`` file which contains
    the VCS output, for systems where the appropriate VCS is not installed or
    there is no VCS metadata directory present. ``version.txt`` can (and
    probably should!) be packaged in release tarballs by way of the
    ``MANIFEST.in`` file.

    :param include_dev_version: By default, if there are any commits after the
        most recent tag (as reported by the VCS), that number will be included
        in the version number as a ``.post`` suffix. For example, if the most
        recent tag is ``1.0`` and there have been three commits after that tag,
        the version number will be ``1.0.post3``. This behavior can be disabled
        by setting this parameter to ``False``.

    :param root: The directory of the repository root. The default value is the
        current working directory, since when running ``setup.py``, this is
        often (but not always) the same as the current working directory.
        Standard substitutions are performed on this value.

    :param version_file: The name of the file where version information will be
        saved. Reading and writing version files can be disabled altogether by
        setting this parameter to ``None``. Standard substitutions are
        performed on this value.

    :param version_module_paths: A list of python modules which will be
        automatically generated containing ``__version__`` and ``__sha__``
        attributes. For example, with ``package/_version.py`` as a version
        module path, ``package/__init__.py`` could do ``from package._version
        import __version__, __sha__``.

    :param git_args: **Deprecated.** Please use *vcs_args* instead.

    :param vcs_args: The command to run to get a version. By default, this is
        automatically guessed from directories present in the repository root.
        Specify this as a list of string arguments including the program to
        run, e.g. ``['git', 'describe']``. Standard substitutions are performed
        on each value in the provided list.

    :param decrement_dev_version: If ``True``, subtract one from the number of
        commits after the most recent tag. This is primarily for hg, as hg
        requires a commit to make a tag. If the VCS used is hg (i.e. the
        revision starts with ``'hg'``) and *decrement_dev_version* is not
        specified as ``False``, *decrement_dev_version* will be set to
        ``True``.

    :param strip_prefix: A string which will be stripped from the start of
        version number tags. By default this is ``'v'``, but could be
        ``'debian/'`` for compatibility with ``git-dch``.

    :param Popen: Defaults to ``subprocess.Popen``. This is for testing.

    :param open: Defaults to ``open``. This is for testing.

    *root*, *version_file*, and *git_args* each support some substitutions:

    ``%(root)s``
      The value provided for *root*. This is not available for the *root*
      parameter itself.

    ``%(pwd)s``
      The current working directory.

    ``/`` will automatically be translated into the correct path separator for
    the current platform, such as ``:`` or ``\``.

    ``vcversioner`` will perform automatic VCS detection with the following
    directories, in order, and run the specified commands.

       ``%(root)s/.git``

          ``git --git-dir %(root)s/.git describe --tags --long``. ``--git-dir``
          is used to prevent contamination from git repositories which aren't
          the git repository of your project.

       ``%(root)s/.hg``

          ``hg log -R %(root)s -r . --template
          '{latesttag}-{latesttagdistance}-hg{node|short}'``. ``-R`` is
          similarly used to prevent contamination.

    ÚpwdÚrootc                 ó    •— t        | ‰z  «      S )N)r   )ÚvalÚsubstitutionss    €r
   Ú
substitutez find_version.<locals>.substitute’   s   ø€ Ü˜˜}Ñ,Ó-Ð-r   Nz4passing `git_args is deprecated; please use vcs_args)ÚstdoutÚstderrÚVCSz failedz$no VCS could be detected in %(root)rc                  óF   •— ‰sy t        d«       ‰D ]  } t        | «       Œ y )Nz-- VCS output follows --)r   )ÚlineÚ
vcs_outputs    €r
   Úshow_vcs_outputz%find_version.<locals>.show_vcs_output¸   s#   ø€ ÙØÜÐ(Ô)ÛˆDÜ�$�Kñ r   r   é   z and z isn't present.z)are you installing from a github tarball?ÚrbÚ-z (from z$) couldn't be parsed into a version.Úwr   Té   Ú0z.postzh
# This file is automatically generated by setup.py.
__version__ = {0}
__sha__ = {1}
__revision__ = {1}
Úu)r   ÚgetcwdÚwarningsÚwarnÚDeprecationWarningÚ_vcs_args_by_pathÚpathÚexistsÚ
subprocessÚPIPEÚcommunicateÚstripÚdecodeÚ
splitlinesÚOSErrorr   Ú
SystemExitÚreadÚreprÚrsplitÚ
ValueErrorÚ
startswithÚlenÚwriteÚstrÚintÚformatÚlstripr   )Úinclude_dev_versionr   Úversion_fileÚversion_module_pathsÚgit_argsÚvcs_argsÚdecrement_dev_versionÚstrip_prefixÚPopenÚopenr"   r6   ÚargsÚraw_versionÚargÚprocr#   r$   Úversion_sourceÚfailurer)   ÚinfileÚtag_versionÚcommitsÚshaÚoutfileÚversionr!   r(   s                              @@r
   Úfind_versionr`   4   s.  ù€ ðx œBŸI™I›KÐ(€MØ  =Ñ0€M�&Ñô.àÐÙ! ,Ó/ˆàÐÜ�‰ØBÜô	 ð ˆàÐß+‰JˆD�$Ü�w‰w�~‰~™j¨Ó.Õ/Ø�Ùð ,ð
 €KØ€JàÐÙ/7Ó8©x¨‘J˜s•O¨xˆÐ8ð	#Ù˜¬*¯/©/Ä*Ç/Á/ÔRˆDð "×-Ñ-Ó/‰NˆF�FØ Ÿ,™,›.×/Ñ/Ó1ˆKØŸ™›×3Ñ3Ó5ˆJØ"ˆNÚ!)Ð+‰à8¸=ÑHˆôñ ØÐÜš7Ð$Ô%ÙÔÜ˜Q“-ÐÜ—‘—‘ Ô-Ü²ºÐFÔGÜÐ=Ô>ÙÔÜ˜Q“-ÐÙ�, Ô%¨Ø Ÿ+™+›-×.Ñ.Ó0ˆK÷ &ä˜lÓ+ˆðØ$/×$6Ñ$6°s¸AÓ$>Ñ!ˆ�W˜cð ×Ñ˜lÔ+Ø!¤# lÓ"3Ð"4Ð5ˆàÐÙ�, Ô$¨Ø�M‰M˜+Ô&÷ %ð ‡~�~�dÔÐ 5Ð =Ø $ÐáÜ”c˜'“l QÑ&Ó'ˆà�#‚~Ñ0Ø‰â!,©gÐ6ˆã$ˆÙ�$˜Œ_ Ø�M‰Mð ÷
 �FŒ4�‹=×Ñ Ó$¤d¨3£i×&6Ñ&6°sÓ&;Ó<ô>÷ ˆ_ð %ô �7˜G SÓ)Ð)ùò[ 9øô ò 	Úð	ú÷: &Ñ%ûô ò ÜÚšð)ô 	*áÔÜ˜‹mÐð	ú÷ %Ñ$ú÷ ˆ_úsI   ÂK(Â#'K- Æ%K=ÇL
 ÈL:É?AMË-	K:Ë9K:Ë=LÌ
-L7Ì:MÍM	c                 óL   — t        di |¤Žj                  | j                  _        y)aà  A hook for simplifying ``vcversioner`` use from distutils.

    This hook, when installed properly, allows vcversioner to automatically run
    when specifying a ``vcversioner`` argument to ``setup``. For example::

      from setuptools import setup

      setup(
          setup_requires=['vcversioner'],
          vcversioner={},
      )

    The parameter to the ``vcversioner`` argument is a dict of keyword
    arguments which :func:`find_version` will be called with.

    Nr   )r`   r_   Úmetadata)ÚdistÚattrÚvalues      r
   Úsetuprf   ÷   s   € ô$ )Ñ1¨5Ñ1×9Ñ9€D‡M�MÕr   )Ú__doc__Ú
__future__r   r   Úcollectionsr   r8   r2   Ú
namedtupler   r   r   r   r5   rR   rS   r`   rf   r   r   r
   Ú<module>rk      sƒ   ðñ÷ 8ã Û 	Û Û ð !ˆ+×
 Ñ
  Ð,AÓ
B€ð 
€ò%ò"ðNð;ðÐ ð &*°	Ø4È2Ø¨ÀTØ!Ø!×'Ñ'¨dó	@*óF:r   