I recently wanted to add cover art to my collection of FLAC-encoded audio files. I wrote the following simple script to help me automate the process. Running this script in a given directory (I group my music in directories per artist, followed by a subdirectory for each album) with the name of the album art image file name as argument then automatically embeds the image in the FLAC/Vorbis tag.
#!/bin/bash # # This script embeds a given image (usually .jpg) as album art in the # FLAC files in the present directory (and its subdirectories). # # Time-stamp: <2011-07-31 20:43:23 (lennart)> coverart=$1 find . -name "*.flac" -print0 |xargs -0 metaflac --import-picture-from="$coverart" |
Knap hoor!
so what would an example syntax be if I named the file “add-album-art.sh”
That would be:
./add-album-art.sh cover.jpg
, which will tag all flac files in the current directory with thecover.jpg
image (assuming the cover image is also stored in the current directory).How about just using metaflac directly? There is no need for find:
metaflac --import-picture-from=cover.jpg *.flac
I’ve been searching for a few days now.. not sure why it took me so long.. but THANK YOU!!!! For some reason finding how to embed album art into flac is hard to find