
    !Sh                        d dl mZ d dlZd dlZd dlZd dlZ	 d dlmZ n$# e	$ r 	 d dlm
Z n# e	$ r	 d dlm
Z Y nw xY wY nw xY wd dlZd dlmZmZmZ  ej        d          Zd
dZd Zed	k    r e             dS dS )    )annotationsN)unsafe_load)load)DEBUGWARNINGCRITICALMARKDOWNc           	     P   d}d}dt           j        z  }t          j        |||          }|                    ddddd	d
           |                    dddd           |                    dddddd           |                    dddddd           |                    dd d!d"d#d$%           |                    d&d'd(dd)d*           |                    d+d,t
          d-t
          d.z   d/d01           |                    d2d3d-t          d/d45           |                    d6d-t          d/d75           |                    | |          \  }} t          |           d8k    rd}n| d8         }|j
        sg |_
        i }|j        r{t          |j        d9|j        :          5 }		 t          |	          }n5# t          $ r(}
d;|j        z  }|f|
j        d<d         z   |
_         d}
~
ww xY w	 ddd           n# 1 swxY w Y   ||j        |j
        ||j        |j        |j        d=}||j        fS )>zE
    Define and parse `optparse` options for command-line usage.
    zN%prog [options] [INPUTFILE]
       (STDIN is assumed if no INPUTFILE is given)zUA Python implementation of John Gruber's Markdown. https://Python-Markdown.github.io/z	%%prog %s)usagedescriptionversionz-fz--filefilenameNz0Write output to OUTPUT_FILE. Defaults to STDOUT.OUTPUT_FILE)destdefaulthelpmetavarz-ez
--encodingencodingz$Encoding for input and output files.)r   r   z-oz--output_formatoutput_formatxhtmlOUTPUT_FORMATz.Use output format 'xhtml' (default) or 'html'.)r   r   r   r   z-nz--no_lazy_ollazy_olstore_falseTz.Observe number of first item of ordered lists.)r   actionr   r   z-xz--extensionappend
extensionszLoad extension EXTENSION.	EXTENSION)r   r   r   r   z-cz--extension_configs
configfileaq  Read extension configurations from CONFIG_FILE. CONFIG_FILE must be of JSON or YAML format. YAML format requires that a python YAML library be installed. The parsed JSON or YAML must result in a python dictionary which would be accepted by the 'extension_configs' keyword on the markdown.Markdown class. The extensions must also be loaded with the `--extension` option.CONFIG_FILEz-qz--quietstore_const
   verbosezSuppress all warnings.)r   r   constr   r   z-vz	--verbosezPrint all warnings.)r   r#   r   r   z--noisyzPrint debug messages.r   r)moder   z(Failed parsing extension config file: %s   )inputoutputr   extension_configsr   r   r   )markdown__version__optparseOptionParser
add_optionr   r   r   
parse_argslenr   r   openr   	yaml_load	Exceptionargsr   r   r   r"   )r4   valuesr   descverparseroptions
input_filer)   fpemessageoptss                W/var/www/html/movieo_spanner_bot/venv/lib/python3.11/site-packages/markdown/__main__.pyparse_optionsr@   -   sJ   6E0D
,
,C"D#NNNF
dH:tM+  - - - dLzA  D D D
d-O%K  M M M dN*DK  M M M dM(6  M M M
d1'. ,  
- 
- 
- dIx*(2+I3  5 5 5 dK*'	0  2 2 2 i*%i2  4 4 4 ''f55OWd
4yyA~~

!W
   
S73C
 
 
 		$-bMM!!   D!,-!afQRRj0	 "			 		 		 		 		 		 		 		 		 		 		 		 		 		 		 "(.$ .? D   s6   G1F/.G1/
G!9#GG!!G11G58G5c                    t                      \  } }| st          j        d           t                              |           t          j                    }t                              |           |t          k    rQt          j
        d           t          j        d           t          j        d          }|                    |           t          j        di |  dS )z#Run Markdown from the command line.   r   Tzpy.warningsN )r@   sysexitloggersetLevelloggingStreamHandler
addHandlerr   warningsfilterwarningscaptureWarnings	getLoggerr*   markdownFromFile)r9   logging_levelconsole_handlerwarn_loggers       r?   runrS   ~   s     +__G] 
OOM"""+--O
o&&&	***%%%'66/// (((((((    __main__)NN)
__future__r   rD   r,   rK   r*   yamlr   r2   ImportErrorr   jsonrH   r   r   r   rN   rF   r@   rS   __name__rC   rT   r?   <module>r[      sL  ( # " " " " " 



   + .------ + + ++******* + + +********+	+  , , , , , , , , , ,		:	&	&N! N! N! N!b) ) )* z CEEEEE s)    A ,A :A :A A 