관리-도구
편집 파일: command.cpython-311.pyc
� �܋f`S � �\ � d dl mZ d dlZd dlmZ d dlmZ d dlmZ d dlmZ ddlm Z dd lmZ dd lm Z ddlmZ erd dlmZ d d lmZ ddlmZ d@d�Z dAdBd�Z dCdDd)�ZdEd+�Z dFdGd.�Z dHdId1�Z dHdId2�Zd3� Z dJdKd7�ZdLd8�ZdMd9�ZdMdNd:�Z dOdPd<�Z!dQd>�Z"dMdRd?�Z#dS )S� )�annotationsN)�List)�Optional)� TYPE_CHECKING)�Union� )�autogenerate)�util)�EnvironmentContext)�ScriptDirectory)�Config)�Script)�ProcessRevisionDirectiveFn�configr c � � | � d� � t j | � � � � � D ]�}t t j � | � � � |d� � � � 5 }t |� � � � � }ddd� � n# 1 swxY w Y | � d||� � ��| � d� � | � d� � dS )zNList available templates. :param config: a :class:`.Config` object. zAvailable templates: �READMENz%s - %sz1 Templates are used via the 'init' command, e.g.:z, alembic init --template generic ./scripts) �print_stdout�os�listdir�get_template_directory�open�path�join�next�rstrip)r �tempname�readme�synopsiss �F/opt/cloudlinux/venv/lib64/python3.11/site-packages/alembic/command.py�list_templatesr s& � � ���0�1�1�1��J�v�<�<�>�>�?�?� ;� ;�� ��G�L�L��6�6�8�8�(�H�M�M� � � -� ��F�|�|�*�*�,�,�H� -� -� -� -� -� -� -� -� -� -� -���� -� -� -� -� ���I�x��:�:�:�:� ���L�M�M�M� ���G�H�H�H�H�Hs �>"B,�,B0 �3B0 �genericF� directory�str�template�package�bool�return�Nonec � � t j |t j � � r+t j |� � rt j d|z � � �t j � | � � � |� � }t j |t j � � st j d|z � � �t j |t j � � sct j dt j � |� � ��fi | j ��5 t j |� � ddd� � n# 1 swxY w Y t j � |d� � }t j dt j � |� � ��fi | j ��5 t j |� � ddd� � n# 1 swxY w Y t |� � }d}t j |� � D ]�}t j � ||� � } |dk r�| j �J �t j � | j � � }t j |t j � � rt j d|�d�fi | j �� ��|� | ||� � � ��t j � | � � r6t j � ||� � } |� | | � � ��|r�t j � t j � |� � d � � t j � t j � |� � d � � fD ]Y}t j di | j ��5 t'