File manager - Edit - /opt/saltstack/salt/lib/python3.10/site-packages/salt/modules/__pycache__/pacmanpkg.cpython-310.pyc
Back
o ;j5 � @ sL d Z ddlZddlZddlZddlZddlZddlZddl Zddl ZddlZddlZddl mZmZ ddlmZ e�e�ZdZdd� Zdd � Zd d� Zejj�ed�Zd d� Zd2dd�Zdd� Zdd� Z d3dd�Z!dd� Z"dd� Z#dd� Z$d4dd�Z% d5d d!�Z&d2d"d#�Z'd6d%d&�Z(d7d'd$�Z)d7d(d)�Z*d*d+� Z+d,d-� Z,d.d/� Z-d0d1� Z.dS )8aq A module to wrap pacman calls, since Arch is the best (https://wiki.archlinux.org/index.php/Arch_is_the_best) .. important:: If you feel that Salt should be using this module to manage packages on a minion, and it is using a different module (or gives an error similar to *'pkg.install' is not available*), see :ref:`here <module-provider-override>`. � N)�CommandExecutionError�MinionError��LooseVersion�pkgc C s t d dkrtS dS )z6 Set the virtual pkg module if the os is Arch Z os_familyZArch)Fz=The pacman module could not be loaded: unsupported OS family.)Z __grains__�__virtualname__� r r �J/opt/saltstack/salt/lib/python3.10/site-packages/salt/modules/pacmanpkg.py�__virtual__ s r c s � fdd�| D �S )zS List the packages which have been removed between the two package objects c s g | ]}|� vr|�qS r r ��.0�x��newr r � <listcomp>- � z!_list_removed.<locals>.<listcomp>r )�oldr r r r � _list_removed) s r c O s� t jj�|�dd��}| sdS |rt� i }| D ]}d||<