File manager - Edit - /opt/imunify360/venv/lib/python3.11/site-packages/imav/patchman/fs_scanner/__pycache__/main.cpython-311.opt-1.pyc
Back
� ,|_j� � �� � d Z ddlZddlZddlZddlmZ ddlmZ ddlm Z m Z mZ ddlmZm Z ej e� � Z G d� dej � � Z G d � d ej � � Zd� Zedk r e� � dS dS ) u This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see <https://www.gnu.org/licenses/>. Copyright © 2019 Cloud Linux Software Inc. This software is also available under ImunifyAV commercial license, see <https://www.imunify360.com/legal/eula> � N)�HashCalculator)�DB)�PatchDependenciesMatcher�VersionsMatcher� HashesMatcher)�all_possible_relative_paths�dir_traverse_generatorc � � e Zd ZdZdd�ZdS )�ReadableFileActionz0 Check that file exists and is readable Nc � � t j � |� � st |� d�� � �t j |t j � � st |� d�� � �t || j |� � d S )Nz does not existz is not readable)�os�path�isfile� ValueError�access�R_OK�setattr�dest)�self�parser� namespace�values� option_strings �R/opt/imunify360/venv/lib/python3.11/site-packages/imav/patchman/fs_scanner/main.py�__call__zReadableFileAction.__call__1 sv � ��w�~�~�f�%�%� 9���7�7�7�8�8�8��y����)�)� :���8�8�8�9�9�9�� �4�9�f�-�-�-�-�-� �N��__name__� __module__�__qualname__�__doc__r � r r r r , s2 � � � � � �� �.� .� .� .� .� .r r c � � e Zd ZdZdd�ZdS )�WritableFilePathActionz* Check that file path is writable Nc �� � t j � |� � pd}t j |t j � � st d|� d�� � �t || j |� � d S )N�.z Directory z is not writable)r r �dirnamer �W_OKr r r )r r r r r �dir_names r r zWritableFilePathAction.__call__>