https://github.com/gitmotion/audio-metadata-updater
Programmatically update meta data of audio files in a given directory and specified file type using python & mutagen.easyid3
https://github.com/gitmotion/audio-metadata-updater
Last synced: 7 months ago
JSON representation
Programmatically update meta data of audio files in a given directory and specified file type using python & mutagen.easyid3
- Host: GitHub
- URL: https://github.com/gitmotion/audio-metadata-updater
- Owner: gitmotion
- Created: 2023-09-14T21:43:11.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-09-15T19:57:16.000Z (over 2 years ago)
- Last Synced: 2025-05-22T00:13:49.838Z (10 months ago)
- Language: Python
- Homepage:
- Size: 21.5 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 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

# Execution
Debugging:

- uncomment following lines and comment lines after

- this will allow you to input the arguments
Terminal:
- 
- 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:

Before:

After:

View Log:
[amdu-demo-log.txt](https://github.com/gitchrishan/audio-metadata-updater/files/12614815/amdu-demo-log.txt)