<s> """<STR_LIT>""" <EOL> from gonzo . exceptions import MultipleResourcesError , NoSuchResourceError <EOL> from gonzo . backends import get_current_cloud <EOL> from gonzo . utils import abort <EOL> def image_delete ( args ) : <EOL> """<STR_LIT>""" <EOL> cloud = get_current_cloud ( ) <EOL> image = cloud . get_image_by_name ( args . image_name ) <EOL> if image is not None : <EOL> image . delete ( ) <EOL> def main ( args ) : <EOL> try : <EOL> image_delete ( args ) <EOL> except NoSuchResourceError as ex : <EOL> print ex . message <EOL> except MultipleResourcesError as ex : <EOL> abort ( ex . message ) <EOL> def init_parser ( parser ) : <EOL> parser . add_argument ( <EOL> '<STR_LIT>' , help = "<STR_LIT>" ) </s>
