-
-
Save kepstin/2c23f3ecc0a60f188273931527de5c12 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import mutagen | |
import mutagen.easymp4 | |
import sys | |
if len(sys.argv) < 3: | |
print "Usage: %s src.flac dest.m4a" % (sys.argv[0]) | |
sys.exit(1) | |
flacfile = mutagen.File(sys.argv[1]) | |
aacfile = mutagen.easymp4.EasyMP4(sys.argv[2]) | |
for tag in flacfile: | |
try: | |
aacfile[tag] = flacfile[tag] | |
except mutagen.easymp4.EasyMP4KeyError: | |
pass | |
aacfile.save() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment