mirror of
https://github.com/beetbox/beets.git
synced 2025-12-15 21:14:19 +01:00
Include import of __future__ features division, absolute_imports and print_function everywhere. Don't add unicode_literals yet for it is harder to convert. Goal is smoothing the transition to python 3.
21 lines
572 B
Python
21 lines
572 B
Python
from __future__ import division, absolute_import, print_function
|
|
|
|
from beets.plugins import BeetsPlugin
|
|
from beets import ui
|
|
|
|
|
|
class TestPlugin(BeetsPlugin):
|
|
def __init__(self):
|
|
super(TestPlugin, self).__init__()
|
|
self.is_test_plugin = True
|
|
|
|
def commands(self):
|
|
test = ui.Subcommand('test')
|
|
test.func = lambda *args: None
|
|
|
|
# Used in CompletionTest
|
|
test.parser.add_option('-o', '--option', dest='my_opt')
|
|
|
|
plugin = ui.Subcommand('plugin')
|
|
plugin.func = lambda *args: None
|
|
return [test, plugin]
|