U
    b                     @   sP   d dl mZmZmZmZ d dlmZ ddlmZ ddl	m
Z
 eeZdd ZdS )	    )absolute_importdivisionprint_functionunicode_literals)	getLogger   )context)on_winc                    s  ddl m  ddlm}m}m} | jr0|tjS t fdd| j	D }|rddl
m} ddlm} |d|||t f | jr }n
t| j	}|strd	nd
}| jrt|dkstd|d }	||	S | j}
| jr| jr| jsd}
| jrd}
to | j}|tj||
| j|| jS d S )Nr   COMPATIBLE_SHELLS)
initializeinitialize_devinstallc                 3   s   | ]}| kr|V  qd S )N ).0sr
   r   2lib/python3.8/site-packages/conda/cli/main_init.py	<genexpr>   s      zexecute.<locals>.<genexpr>)ArgumentError)dashlistz5Invalid shells: %s

Currently available shells are:%s)zcmd.exeZ
powershell)Zbash   z3--dev can only handle one shell at a time right nowr   TF)Zbase.constantsr   Zcore.initializer   r   r   r   Zconda_prefixtupleZshells
exceptionsr   Z	common.ior   sortedallr	   ZdevlenAssertionErrorusersystemZno_useranaconda_promptreverse)argsparserr   r   r   Zinvalid_shellsr   r   Zselected_shellsshellZfor_userr   r   r
   r   execute   s<    

 r$   N)Z
__future__r   r   r   r   Zloggingr   Zbase.contextr   Zcommon.compatr	   __name__logr$   r   r   r   r   <module>   s
   