From 80bec3935e91647593317c3ed1995dd6217e573e Mon Sep 17 00:00:00 2001 From: Adrian Sampson Date: Tue, 22 Apr 2014 14:50:54 -0700 Subject: [PATCH] config name change, changelog for #692 --- beetsplug/ftintitle.py | 8 +++++--- docs/changelog.rst | 2 ++ docs/plugins/ftintitle.rst | 5 +++-- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/beetsplug/ftintitle.py b/beetsplug/ftintitle.py index 34cdbdcc6..831236b3c 100644 --- a/beetsplug/ftintitle.py +++ b/beetsplug/ftintitle.py @@ -51,6 +51,8 @@ def contains_feat(title): def update_metadata(item, feat_part, drop_feat): """Choose how to add new artists to the title and set the new metadata. Also, print out messages about any changes that are made. + If `drop_feat` is set, then do not add the artist to the title; just + remove it from the artist field. """ # In all cases, update the artist fields. ui.print_(u'artist: {0} -> {1}'.format(item.artist, item.albumartist)) @@ -116,7 +118,7 @@ class FtInTitlePlugin(BeetsPlugin): super(FtInTitlePlugin, self).__init__() self.config.add({ - 'drop_feat': False + 'drop': False }) self._command = ui.Subcommand( @@ -124,7 +126,7 @@ class FtInTitlePlugin(BeetsPlugin): help='move featured artists to the title field') self._command.parser.add_option( - '-d', '--drop', dest='drop_feat', + '-d', '--drop', dest='drop', action='store_true', default=False, help='drop featuring from artists and ignore title update') @@ -132,7 +134,7 @@ class FtInTitlePlugin(BeetsPlugin): def func(lib, opts, args): self.config.set_args(opts) - drop_feat = self.config['drop_feat'].get(bool) + drop_feat = self.config['drop'].get(bool) write = config['import']['write'].get(bool) for item in lib.items(ui.decargs(args)): diff --git a/docs/changelog.rst b/docs/changelog.rst index f0c8f5471..faae62c35 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -6,6 +6,8 @@ Changelog * The new :doc:`/plugins/play` lets you start your desktop music player with the songs that match a query. Thanks to David Hamp-Gonsalves. +* :doc:`/plugins/ftintitle`: A new option lets you remove featured artists + entirely instead of moving them to the title. Thanks to SUTJael. Fixes: diff --git a/docs/plugins/ftintitle.rst b/docs/plugins/ftintitle.rst index dc457a495..ed13cb840 100644 --- a/docs/plugins/ftintitle.rst +++ b/docs/plugins/ftintitle.rst @@ -17,7 +17,8 @@ To use the plugin, just enable it and run the command:: The query is optional; if it's left off, the transformation will be applied to your entire collection. -The ``-d`` option drop only featuring information from the ``artist`` field. The -``title`` field will not be updated. +If you prefer to remove featured artists entirely instead of adding them to +the title field, either use the ``-d`` flag to the command or set the +``ftintitle.drop`` config option. .. _MusicBrainz style: http://musicbrainz.org/doc/Style