File: //opt/saltstack/salt/lib/python3.10/site-packages/salt/modules/__pycache__/composer.cpython-310.pyc
o
�N�g0) � @ s� d Z ddlZddlZddlZddlZddlmZm Z m
Z
e�e�Z
ddiZdd� Zdd � Zd
d� Z
ddd�Z
ddd�Z
ddd�Zddd�ZdS )z:
Use composer to install PHP dependencies for a directory
� N)�CommandExecutionError�CommandNotFoundError�SaltInvocationErrorZlist_�listc C s dS )z
Always load
T� r r r �I/opt/saltstack/salt/lib/python3.10/site-packages/salt/modules/composer.py�__virtual__ s r c C s t jj�| �r dS dS )z5
Validate the composer file is indeed there.
TF)�salt�utils�path�which)�composerr r r �_valid_composer s r c C s | � d�}t j�|�r
dS dS )z�
Test to see if the vendor directory exists in this directory
dir
Directory location of the composer.json file
CLI Example:
.. code-block:: bash
salt '*' composer.did_composer_install /var/www/application
z/vendorTF)�osr �exists)�dirZlockFiler r r �did_composer_install&