
                             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  \
R$                  " \
R&                  R(                  5       " S S\
R*                  5      5       rg)z(Delete github enterprise config command.    )absolute_import)division)unicode_literals)cloudbuild_util)waiter)base)flags)log)
properties)	resourcesc                   .    \ rS rSrSr\S 5       rS rSrg)DeleteAlpha   z3Delete a github enterprise config from Cloud Build.c                 P    U R                  SSS9  [        R                  " U SSS9  g)zRegister flags for this command.

Args:
  parser: An argparse.ArgumentParser-like object. It is mocked out in order
    to capture some information, but behaves like an ArgumentParser.
CONFIGz&The id of the GitHub Enterprise Config)helpF)hiddenrequiredN)add_argumentbuild_flagsAddRegionFlag)parsers    5lib/surface/builds/enterprise_config/github/delete.pyArgsDeleteAlpha.Args"   s*     'OPfUUC    c           	      .   [         R                  " 5       n[         R                  " 5       n[        R                  R
                  R                  R                  SS9n[        R                  R                  R                  R                  5       nUR                  =(       d    U=(       d    [         R                  nUR                  n[        R                  R                  SSSUUUS.S9nUR                  R!                  UR#                  UR%                  5       UUS95      n	[        R                  R'                  U	R(                  S	S
9n
[*        R,                  " [*        R.                  " UR0                  5      U
S5        [2        R4                  " U5        g)zThis is what gets called when the user runs this command.

Args:
  args: an argparse namespace. All the arguments that were provided to this
    command invocation.

Returns:
  Nothing on success.
T)r   Nz5cloudbuild.projects.locations.githubEnterpriseConfigsv1)
projectsIdgithubEnterpriseConfigsIdlocationsId)
collectionapi_versionparams)nameconfigId	projectIdz(cloudbuild.projects.locations.operations)r"   z!Deleting GitHub Enterprise Config)r   GetClientInstanceGetMessagesModuler   VALUEScoreprojectGetbuildsregionDEFAULT_REGIONr   r   REGISTRYParse*projects_locations_githubEnterpriseConfigsDelete?CloudbuildProjectsLocationsGithubEnterpriseConfigsDeleteRequestRelativeNameParseRelativeNamer%   r   WaitForCloudOperationPollerNoResourcesprojects_locations_operationsr
   DeletedResource)selfargsclientmessagesparent
regionproplocation	config_idghe_resource
deleted_opop_resources              r   RunDeleteAlpha.Run-   sZ    ..0F002H##++///>F""))00446J{{JjJO,J,JHI %%++J )2#
	 , L BBIIPP**, 	Q 	J
 $$66$N 7 PK
NN..00	23>+- %r    N)	__name__
__module____qualname____firstlineno____doc__staticmethodr   rG   __static_attributes__rI   r   r   r   r      s    ;D D+&r   r   N)rN   
__future__r   r   r   !googlecloudsdk.api_lib.cloudbuildr   googlecloudsdk.api_lib.utilr   googlecloudsdk.callioper   !googlecloudsdk.command_lib.buildsr	   r   googlecloudsdk.corer
   r   r   ReleaseTracksReleaseTrackALPHADeleteCommandr   rI   r   r   <module>r[      s`    / &  ' = . ( B # * ) D%%++,9&$$$ 9& -9&r   