Skip to content

Instantly share code, notes, and snippets.

@djromero
Created April 4, 2014 15:05
Show Gist options
  • Save djromero/9976547 to your computer and use it in GitHub Desktop.
Save djromero/9976547 to your computer and use it in GitHub Desktop.
Change ID3 tags in the command line with id3v2.
#!/bin/bash
# Copy the Artist tag to Artist Album.
# Requires id3v2 [brew install id3vw]
#
DIR="500 Greatest Songs"
find "$DIR" -name "*mp3" | while read song
do
artist=`id3v2 --list "$song" | grep TPE1 | cut -d: -f 2 | sed -e 's/^ //'`
echo $artist
id3v2 --TPE2 "${artist}" "$song"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment