move enabled backends option to BaseApplication
This commit is contained in:
parent
560a129083
commit
7a86ddfbb6
2 changed files with 4 additions and 8 deletions
|
|
@ -25,15 +25,8 @@ class Videoob(ConsoleApplication):
|
|||
APPNAME = 'videoob'
|
||||
CONFIG = {}
|
||||
|
||||
def configure_parser(self, parser):
|
||||
parser.add_option('-b', '--backends', help='what backend(s) to enable (comma separated)')
|
||||
|
||||
def main(self, argv):
|
||||
names = None
|
||||
if self.options.backends:
|
||||
names = self.options.backends.split(',')
|
||||
|
||||
self.weboob.load_modules(ICapVideoProvider, names=names)
|
||||
self.weboob.load_modules(ICapVideoProvider, names=self.enabled_backends)
|
||||
return self.process_command(*argv[1:])
|
||||
|
||||
@ConsoleApplication.command('Get video information')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue