aboutsummaryrefslogtreecommitdiff
path: root/youtube_dl/__init__.py
diff options
context:
space:
mode:
authorPhilipp Hagemeister <phihag@phihag.de>2014-01-07 05:44:44 +0100
committerPhilipp Hagemeister <phihag@phihag.de>2014-01-07 05:44:44 +0100
commit5f263296eaa72ddca232d734a2625bcd85771908 (patch)
tree20be6ebdfb0b1f36c789c7f0cf86f70b0a5c2e69 /youtube_dl/__init__.py
parent89650ea3a680a383d7e6129e9c11b129a23e9150 (diff)
parente63fc1bed423e7b84e257000d7d25bb812d37685 (diff)
Merge remote-tracking branch 'epitron/metadata-pp'
Conflicts: youtube_dl/PostProcessor.py
Diffstat (limited to 'youtube_dl/__init__.py')
-rw-r--r--youtube_dl/__init__.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/youtube_dl/__init__.py b/youtube_dl/__init__.py
index edaf1f1cd..ba243d4d2 100644
--- a/youtube_dl/__init__.py
+++ b/youtube_dl/__init__.py
@@ -38,6 +38,7 @@ __authors__ = (
'Takuya Tsuchida',
'Sergey M.',
'Michael Orlitzky',
+ 'Chris Gahan',
)
__license__ = 'Public Domain'
@@ -79,6 +80,7 @@ from .PostProcessor import (
FFmpegVideoConvertor,
FFmpegExtractAudioPP,
FFmpegEmbedSubtitlePP,
+ XAttrMetadataPP,
)
@@ -415,7 +417,9 @@ def parseOpts(overrideArguments=None):
postproc.add_option('--embed-subs', action='store_true', dest='embedsubtitles', default=False,
help='embed subtitles in the video (only for mp4 videos)')
postproc.add_option('--add-metadata', action='store_true', dest='addmetadata', default=False,
- help='add metadata to the files')
+ help='write metadata to the video file')
+ postproc.add_option('--xattrs', action='store_true', dest='xattrs', default=False,
+ help='write metadata to the video file\'s xattrs (using dublin core and xdg standards)')
parser.add_option_group(general)
@@ -717,6 +721,8 @@ def _real_main(argv=None):
ydl.add_post_processor(FFmpegVideoConvertor(preferedformat=opts.recodevideo))
if opts.embedsubtitles:
ydl.add_post_processor(FFmpegEmbedSubtitlePP(subtitlesformat=opts.subtitlesformat))
+ if opts.xattrs:
+ ydl.add_post_processor(XAttrMetadataPP())
# Update version
if opts.update_self: