mirror of
https://github.com/beetbox/beets.git
synced 2025-12-11 19:16:07 +01:00
More flexible title splitting (#1060)
These tokens should not be artist-exclusive.
This commit is contained in:
parent
c2c1e7236d
commit
af11dedb51
1 changed files with 2 additions and 2 deletions
|
|
@ -686,9 +686,9 @@ def feat_tokens(for_artist=True):
|
|||
The `for_artist` option determines whether the regex should be
|
||||
suitable for matching artist fields (the default) or title fields.
|
||||
"""
|
||||
feat_words = ['ft', 'featuring', 'feat']
|
||||
feat_words = ['ft', 'featuring', 'feat', 'feat.', 'ft.']
|
||||
if for_artist:
|
||||
feat_words += ['with', 'vs', 'and', 'con', '&', 'feat.', 'ft.']
|
||||
feat_words += ['with', 'vs', 'and', 'con', '&']
|
||||
return '(?<=\s)(?:{0})(?=\s)'.format(
|
||||
'|'.join(re.escape(x) for x in feat_words)
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in a new issue