Skip to content

Programmatically update meta data of audio files in a given directory and specified file type using python & mutagen.easyid3

Notifications You must be signed in to change notification settings

gitmotion/audio-metadata-updater

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 

Repository files navigation

audio-metadata-updater

  • Uses mutagen.easyid3
  • Add songs files to a given directory
  • Generate / create a .json file that contains all the metadata you want to update
  • current supported metadata fields: title, artist, album, tracknumber, composer, albumartist, discnumber, copyright
  • Comes with error handling and will list out files that failed to update at the end of the log

Note: File name will be used as the key in the metadata.json file and must be configured accordingly

  • Certain special characters (?, >, <, etc) can't be added to file names and will need to be taken out of the .json file keys to account for this
  • However you can still add them in the metadata info
  • As long as the file name and the keys in the metadata.json match up you can essentially use any identifier

specialcharacterexample

Execution

Debugging:
debugmodeexecution

  • uncomment following lines and comment lines after

debug_mode

  • this will allow you to input the arguments

Terminal:

  • terminalexecution
    • uncomment following lines and comment lines before
  • Using python, execute as such:
    python path/to/amdu.py /path/to/song/directory .mp3 /path/to/metadata.json
    Or
    python .\amdu.py '.\AUDIO_FILE_DIRECTORY\' .mp3 '.\metadata.json' (powershell)
    - you can use any audio file extensions supported by mutagen (see documentation)
  • This will grab all *.mp3 files (or any other specified extensions) in the given directory and parse the metadata.json file and match them accordingly

Demo & Results

Demo:
amdu demo

Before:
before

After:
after

View Log:
amdu-demo-log.txt

About

Programmatically update meta data of audio files in a given directory and specified file type using python & mutagen.easyid3

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages