def list_(channel=None):
 pecl_channel_pat = re.compile('^([^ ]+)[ ]+([^ ]+)[ ]+([^ ]+)')
 pecls = {}
 command = 'list'
 if channel:
  command = '{0} -c {1}'.format(command, _cmd_quote(channel))
 lines = _pecl(command).splitlines()
 lines = (l for l in lines if pecl_channel_pat.match(l))
 for line in lines:
  match = pecl_channel_pat.match(line)
  if match:
   pecls[match.group(1)] = [match.group(2), match.group(3)]
 return pecls

def list_ ( channel = None ) : pecl_channel_pat = re . compile ( '^([^ ]+)[ ]+([^ ]+)[ ]+([^ ]+)' ) pecls = { } command = 'list' if channel : command = '{0} -c {1}' . format ( command , _cmd_quote ( channel ) ) lines = _pecl ( command ) . splitlines ( ) lines = ( l for l in lines if pecl_channel_pat . match ( l ) ) for line in lines : match = pecl_channel_pat . match ( line ) if match : pecls [ match . group ( 1 ) ] = [ match . group ( 2 ) , match . group ( 3 ) ] return pecls
list installed perl modules .