def list_state_modules(*args):
 st_ = salt.state.State(__opts__)
 modules = set()
 if (not args):
  for func in st_.states:
   log.debug('func {0}'.format(func))
   modules.add(func.split('.')[0])
  return sorted(modules)
 for module in args:
  if ('*' in module):
   for func in fnmatch.filter(st_.states, module):
    modules.add(func.split('.')[0])
  else:
   for func in st_.states:
    mod_test = func.split('.')[0]
    if (mod_test == module):
     modules.add(mod_test)
 return sorted(modules)

def list_state_modules ( * args ) : st_ = salt . state . State ( __opts__ ) modules = set ( ) if ( not args ) : for func in st_ . states : log . debug ( 'func {0}' . format ( func ) ) modules . add ( func . split ( '.' ) [ 0 ] ) return sorted ( modules ) for module in args : if ( '*' in module ) : for func in fnmatch . filter ( st_ . states , module ) : modules . add ( func . split ( '.' ) [ 0 ] ) else : for func in st_ . states : mod_test = func . split ( '.' ) [ 0 ] if ( mod_test == module ) : modules . add ( mod_test ) return sorted ( modules )
list the modules loaded on the minion .