'Activate a plugin for use and enter context'

def do_use(self, input):

    (argc, argv) = util.parseinput(input, 2)
    if (argc == 0):
        for manager in self.get_manager_list():
            plugins = [(plugin.getName(), plugin.getVersion()) for plugin in manager.get_plugins()]
            args = {'module': manager.get_name(), 'plugins': plugins}
            self.io.print_module_lists(args)
    elif (argc == 1):
        for manager in self.get_manager_list():
            if (argv[0].lower() in [x.lower() for x in manager.get_plugin_names()]):
                manager.set_active_plugin(argv[0])
                plugin = manager.get_active_plugin()
                self.io.newline()
                self.io.print_warning(('Entering    Plugin    Context    ::    %s' % plugin.getName()))
                self.io.print_msg('Applying    Global    Variables')
                try:
                    plugin.setParameters(self.fbglobalvars)
                except:
                    pass
                self.io.newline()
                self.do_enter(manager.get_type())
                if self.autorun:
                    for (auto, msg) in self.autorunvars.get(manager.get_type(), []):
                        if msg:
                            self.runcmd_noex(('echo    %s' % msg))
                        self.runcmd_noex(auto)
                break
        else:
            raise exception.CmdErr, ('Plugin    %s    not    found!' % argv[0])
