|
Server : Apache System : Linux cvar2.toservers.com 3.10.0-962.3.2.lve1.5.73.el7.x86_64 #1 SMP Wed Aug 24 21:31:23 UTC 2022 x86_64 User : njnconst ( 1116) PHP Version : 8.4.18 Disable Function : NONE Directory : /opt/alt/python37/lib/python3.7/site-packages/clcommon/__pycache__/ |
Upload File : |
B
(
c� � @ sD d dl mZ d dl mZ d dl mZ d dlZdZdd� Zdd � ZdS )
� )�absolute_import)�division)�print_functionNz/var/cpanel/cpanel.configc C sh yt | �}|�� }W n ttfk
r, dS X x4|D ],}|�d| �r4|�� |�� �d�d S q4W dS )z�
Get param from config file
:param path: Path to config file
:type path: str
:param param: Key for param in config file
:type param: str
Fz%s=�=� N)�open� readlines�OSError�IOError�
startswith�close�strip�split)�path�param�fd�data�line� r �B/opt/alt/python37/lib/python3.7/site-packages/clcommon/clconfig.py� get_param s
r c
C s� d||f }t j�| �s<t| d��}|�|� W dQ R X dS t| ��}|�� }W dQ R X xTt|�D ]H\}}|�d| �rb|||<