shell bypass 403
U
��.e�
� @ s| d dl mZ d dlZd dlmZ d dlmZ d dlmZ d dl m
Z
d dlmZ d dl
mZ d d
ddhZG d
d� de�ZdS )� )�absolute_importN)�
WheelCache)�
cmdoptions)�Command)�
FormatControl)�freeze)�stdlib_pkgsZpipZ
setuptoolsZ
distributeZwheelc s0 e Zd ZdZdZdZ� fdd�Zdd� Z� ZS )�
FreezeCommandzx
Output installed packages in requirements format.
packages are listed in a case-insensitive sorted order.
z
%prog [options])�ext://sys.stderrr
c s� t t| �j||� | jjddddg ddd� | jjdd d
dg ddd� | jjd
dddddd� | jjdddddd� | j�t�� � | jjddddd�t� d� | jjddddd� | j �
d| j� d S ) Nz-rz
--requirement�requirements�append�filez}Use the order in the given requirements file and its comments when generating output. This option can be used multiple times.)�dest�action�default�metavar�helpz-fz--find-links�
find_linksZURLz<URL for finding packages, which will be added to the output.z-lz--local�local�
store_trueFzUIf in a virtualenv that has global access, do not output globally-installed packages.)r r r r z--user�userz,Only output packages installed in user-site.z--all�
freeze_allz,Do not skip these packages in the output: %sz, )r r r z--exclude-editable�exclude_editablez%Exclude editable package from output.r )�superr �__init__Zcmd_optsZ
add_optionr Z list_path�join�DEV_PKGS�parserZinsert_option_group)�self�args�kw�� __class__� �A/usr/lib/python3.8/site-packages/pip/_internal/commands/freeze.pyr sd � � �����zFreezeCommand.__init__c C s� t t� t� �}t|j|�}tt�}|js2|�t� t� |� t
|j|j|j
|j|j|j|j|||jd�
}z$tf |�D ]}tj�|d � qtW 5 |�� X d S )N)
Zrequirementr Z
local_onlyZ user_only�pathsZ
skip_regex�isolated�wheel_cache�skipr �
)r �setr � cache_dirr r �updater r Zcheck_list_path_option�dictr r r r �pathZskip_requirements_regexZ
isolated_moder Zcleanupr �sys�stdout�write)r Zoptionsr Zformat_controlr'