
                             S r SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSKJr  SSK	J
r
  SS	KJr  SS
KJr  SSKJr   " S S\
R"                  5      rg)z%`gcloud app services delete` command.    )absolute_import)division)unicode_literals)appengine_api_client)service_util)version_util)base)
console_io)text)movesc                   6    \ rS rSrSrSS0r\S 5       rS rSr	g)	Delete   z'Delete services in the current project.EXAMPLESa:            To delete a service (and all of its accompanying versions) in the
          current project, run:

            $ {command} service1

          To delete multiple services (and all of their accompanying versions)
          in the current project, run:

            $ {command} service1 service2
          c                 F    U R                  SSSS9  U R                  SSS9  g )Nservices+zThe service(s) to delete.)nargshelpz	--versionz2Delete a specific version of the given service(s).)r   )add_argument)parsers    "lib/surface/app/services/delete.pyArgsDelete.Args/   s2    

#4OP
N  P    c                    [         R                  " U R                  5       5      nUR                  5       n[        R
                  " X1R                  5      nUR                  (       a  [        R                  " SR                  UR                  [        R                  " [        U5      S5      SR                  [        R                   " ["        U5      5      5      SS9  U Vs/ s H9  n[$        R&                  " UR(                  UR*                  UR                  5      PM;     nn[$        R,                  " X&5        g [        R                  " SR                  [        R                  " [        U5      S5      SR                  [        R                   " ["        U5      5      5      SS9  [        R.                  " X$5        g s  snf )Nz$Deleting version [{0}] of {1} [{2}].servicez, T)cancel_on_nozDeleting {0} [{1}].)r   GetApiClientForTrackReleaseTrackListServicesr   GetMatchingServicesr   versionr
   PromptContinueformatr   	Pluralizelenjoinr   mapstrr   VersionprojectidDeleteVersionsDeleteServices)selfargs
api_clientall_servicesr   sversionss          r   Run
Delete.Run5   sB   %::4;L;L;NOJ **,L//mmLH||
0
7
7llDNN3x=)Dii		#x013 	 $%#a &&z'9'9144N#  %!!*7

&
&nnS]I6ii		#x013 	
 !!*7%s    A F; N)
__name__
__module____qualname____firstlineno____doc__detailed_helpstaticmethodr   r6   __static_attributes__r8   r   r   r   r      s1    /  
- P P
8r   r   N)r=   
__future__r   r   r   googlecloudsdk.api_lib.appr   r   r   googlecloudsdk.callioper	   googlecloudsdk.core.consoler
   googlecloudsdk.core.utilr   sixr   DeleteCommandr   r8   r   r   <module>rH      s:    , &  ' ; 3 3 ( 2 ) .8T .8r   