def get_details_for_etag(options):
 (tags, noserver) = read_etag_file(options)
 if (noserver and (not options.noserver)):
  options.noserver = noserver
 m = re.match('(?:W/)?"?(.*)"?$', options.etag)
 if m:
  options.etag = m.group(1)
 etag = options.etag
 if (etag in tags):
  print ('Found etag [%s] for version %s' % (etag, tags[etag][0]['version']))
  return tags[etag]
 short = etag[etag.index('-'):]
 for t in tags:
  if (t.find(short) != (-1)):
   print ('Partial ETag match: [%s],[%s] for version %s' % (etag, t, tags[t][0]['version']))
   return tags[t]
 return None

def get_details_for_etag ( options ) : ( tags , noserver ) = read_etag_file ( options ) if ( noserver and ( not options . noserver ) ) : options . noserver = noserver m = re . match ( '(?:W/)?"?(.*)"?$' , options . etag ) if m : options . etag = m . group ( 1 ) etag = options . etag if ( etag in tags ) : print ( 'Found etag [%s] for version %s' % ( etag , tags [ etag ] [ 0 ] [ 'version' ] ) ) return tags [ etag ] short = etag [ etag . index ( '-' ) : ] for t in tags : if ( t . find ( short ) != ( - 1 ) ) : print ( 'Partial ETag match: [%s],[%s] for version %s' % ( etag , t , tags [ t ] [ 0 ] [ 'version' ] ) ) return tags [ t ] return None
get the stack address for a specific etag from the configuration file .