File: //opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/__pycache__/gitfs.cpython-310.pyc
o
�N�g�1 �
@ s
d Z ddlZddlZddlZddlZddlZddlZddlZddlZddl Z ddl
Z
ddlZddlZddl
Z
ddlZddlZddlZddlZddlZddlmZ ddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddl Zddl!Zddl"Zddl#Zddl$Zddl%m&Z& ddl%m'Z( ddl)m*Z*m+Z+m,Z, ddl-m.Z. ddl/m0Z0 dd lm1Z2 dd
l$m3Z3 e(d Z4dZ5d
Z6dZ7dZ8dZ9dZ:dZ;dZ<dZ=e �>e?�Z@dZAzddlBZBdZAW n eCy� Y nw z.ejDjE�F� �r
ejDjG�Hd�dk�r
ddlImJZJ eJ� �r
eCd��ddlKZKddlLZLe3eKjM�ZNW n eO�y' dZNY nw zeddlPZPeP�Q� � eP�Rd� ddlSZSW d � n 1 �sFw Y e3eSjM�ZTe3eSjU�ZUeTe3d�k�ryz
ddlVZSddlWZSW n
eC�yp Y n w dd� ZXeXeSjY_ZzeSj[j\Z\W n e]�y� eOZ\Y nw W n" eO�y� Z^ zdZTdZUe_e^eC��s�e@�`d� W Y dZ^[^ndZ^[^ww e3d �Zae3d!�Zbe3d"�Zcd#d$� Zdd%d&� ZeG d'd(� d(�ZfG d)d*� d*ef�ZgG d+d,� d,ef�Zhehegd-�ZiG d.d/� d/�ZjG d0d1� d1ej�ZkG d2d3� d3ej�ZlG d4d5� d5ej�Zmd6d7� ZndS )8zJ
Classes which provide the shared base for GitFS, git_pillar, and winrepo
� N)�datetime)�DEFAULT_HASH_TYPE)�DEFAULT_MASTER_OPTS)�FileserverConfigError�GitLockError�get_error_message)�tagify)�OrderedDict)�get_machine_identifier)�VersionZgitfs_ref_types��name� �d )�pygit2)�user�password�pubkey�privkey�
passphrase�
insecure_auth)�
mountpoint�root�refzgGitPython is installed, you may wish to set %s_provider to 'gitpython' to use GitPython for %s support.zbpygit2 is installed, you may wish to set %s_provider to 'pygit2' to use pygit2 for for %s support.z�Cache path %s (corresponding remote: %s) exists but is not a valid git repository. You will need to manually delete this directory on the master to continue to use this %s remote.FT�gitz/usr/bin/git)�git_is_stubzGit is not present.�ignorez0.26.3c C s | sd S t j�| ��d�S )N�utf-8)r Zffi�string�decode)�ptrr r �D/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/gitfs.py�__maybe_string� s r"