mirror of
https://github.com/beetbox/beets.git
synced 2025-12-09 18:12:19 +01:00
Rename metadata sync plugin.
This commit is contained in:
parent
73fcbd07c3
commit
c50d59f7e7
3 changed files with 9 additions and 9 deletions
|
|
@ -23,10 +23,10 @@ from sys import modules
|
|||
import inspect
|
||||
|
||||
# Loggers.
|
||||
log = logging.getLogger('beets.psync')
|
||||
log = logging.getLogger('beets.metasync')
|
||||
|
||||
|
||||
class PSyncPlugin(BeetsPlugin):
|
||||
class MetaSyncPlugin(BeetsPlugin):
|
||||
|
||||
item_types = {
|
||||
'amarok_rating': types.INTEGER,
|
||||
|
|
@ -38,10 +38,10 @@ class PSyncPlugin(BeetsPlugin):
|
|||
}
|
||||
|
||||
def __init__(self):
|
||||
super(PSyncPlugin, self).__init__()
|
||||
super(MetaSyncPlugin, self).__init__()
|
||||
|
||||
def commands(self):
|
||||
cmd = ui.Subcommand('psync',
|
||||
cmd = ui.Subcommand('metasync',
|
||||
help='update metadata from music player libraries')
|
||||
cmd.parser.add_option('-p', '--pretend', action='store_true',
|
||||
help='show all changes but do nothing')
|
||||
|
|
@ -53,7 +53,7 @@ class PSyncPlugin(BeetsPlugin):
|
|||
return [cmd]
|
||||
|
||||
def func(self, lib, opts, args):
|
||||
"""Command handler for the psync function.
|
||||
"""Command handler for the metasync function.
|
||||
"""
|
||||
pretend = opts.pretend
|
||||
source = opts.source
|
||||
|
|
@ -62,9 +62,9 @@ class PSyncPlugin(BeetsPlugin):
|
|||
sources = {}
|
||||
|
||||
for player in source:
|
||||
__import__('beetsplug.psync', fromlist=[str(player)])
|
||||
__import__('beetsplug.metasync', fromlist=[str(player)])
|
||||
|
||||
module = 'beetsplug.psync.' + player
|
||||
module = 'beetsplug.metasync.' + player
|
||||
|
||||
if module not in modules.keys():
|
||||
log.error(u'Unknown metadata source \'' + player + '\'')
|
||||
4
setup.py
4
setup.py
|
|
@ -76,7 +76,7 @@ setup(
|
|||
'beetsplug.bpd',
|
||||
'beetsplug.web',
|
||||
'beetsplug.lastgenre',
|
||||
'beetsplug.psync',
|
||||
'beetsplug.metasync',
|
||||
],
|
||||
entry_points={
|
||||
'console_scripts': [
|
||||
|
|
@ -118,7 +118,7 @@ setup(
|
|||
'web': ['flask', 'flask-cors'],
|
||||
'import': ['rarfile'],
|
||||
'thumbnails': ['pathlib', 'pyxdg'],
|
||||
'psync': ['dbus-python'],
|
||||
'metasync': ['dbus-python'],
|
||||
},
|
||||
# Non-Python/non-PyPI plugin dependencies:
|
||||
# replaygain: mp3gain || aacgain
|
||||
|
|
|
|||
Loading…
Reference in a new issue