Add metadata from title parser

(Closes #5125)
This commit is contained in:
phiresky 2015-03-04 22:33:56 +01:00 committed by Jaime Marquínez Ferrándiz
parent 082b1155a3
commit e7db87f700
5 changed files with 72 additions and 2 deletions

View file

@ -735,6 +735,15 @@ def parseOpts(overrideArguments=None):
'--add-metadata',
action='store_true', dest='addmetadata', default=False,
help='write metadata to the video file')
postproc.add_option(
'--metadata-from-title',
metavar='FORMAT', dest='metafromtitle',
help='parse additional metadata like song title / artist from the video title. \n'
'The format syntax is the same as --output, '
'the parsed parameters replace existing values.\n'
'Additional templates: %(songtitle), %(album), %(artist). \n'
'Example: --metadata-from-title "%(artist)s - %(title)s" matches a title like '
'"Coldplay - Paradise"')
postproc.add_option(
'--xattrs',
action='store_true', dest='xattrs', default=False,