diff options
author | Karel Kočí <cynerd@email.cz> | 2015-11-07 15:35:55 +0100 |
---|---|---|
committer | Karel Kočí <cynerd@email.cz> | 2015-11-07 15:35:55 +0100 |
commit | ccc21b09f752d583e3fdca694cd94e61a9fbaa69 (patch) | |
tree | 1cf19174ddcbd39c2dc05557823b5f7d9fc169ec /modules/list-modules.py | |
parent | 2a7c2861b69da4570e90be17ad5e0f36b3ec0527 (diff) | |
download | mcserver-wrapper-ccc21b09f752d583e3fdca694cd94e61a9fbaa69.tar.gz mcserver-wrapper-ccc21b09f752d583e3fdca694cd94e61a9fbaa69.tar.bz2 mcserver-wrapper-ccc21b09f752d583e3fdca694cd94e61a9fbaa69.zip |
Remove modules
Modules are not used any more. They are now useless.
Diffstat (limited to 'modules/list-modules.py')
-rw-r--r-- | modules/list-modules.py | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/modules/list-modules.py b/modules/list-modules.py deleted file mode 100644 index ca93dc3..0000000 --- a/modules/list-modules.py +++ /dev/null @@ -1,51 +0,0 @@ -import sys -import re -import utils -from utils import conf -import importlib.machinery as imp - -services = ( - utils.Service.action, - ) - -def action(args): - if conf.action == None: - if args[0].lower() != 'list-modules': - return False - conf.action = 'list-modules' - conf.action_module = sys.modules[__name__] - return 1 - elif conf.identifier == None: - conf.identifier = args[0] - return 1 - return 0 - -def action_exec(): - if conf.verbose_level >= 1: - for mod in conf.modules: - try: - module = imp.SourceFileLoader(mod, - conf.modulesFolder + '/' + mod + '.py').load_module() - print(module) - for service in module.services: - print(' ' + utils.Service.toStr(service)) - except FileNotFoundError: - sys.exit('Unknown module: ' + mod) - else: - # TODO add check if module exists - for mod in conf.modules: - print(mod) - -def action_help(): - print(' list-modules') - print(' List all modules that will be used.') - -def action_full_help(): - print('mcwrapper [arguments...] list-modules [IDENTIFIER]') - print(' List all modules that will be used.') - print('') - print(' arguments') - utils.printArgumentsHelp() - print(' IDENTIFIER') - print(' Identifier of Minecraft server instance.') - print(' If specified, server modules are printed.') |