Created
July 22, 2012 10:46
-
-
Save devpg/3159247 to your computer and use it in GitHub Desktop.
Returns the genre of a mp3 file (based on its id3v2 tag)
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
#!/bin/bash | |
genre=$(id3v2 -l "$1" | sed -n '/^TCON/s/^.*: //p' | sed 's/ (.*//') | |
echo $genre |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment