Skip to content

Instantly share code, notes, and snippets.

@oscar230
Last active October 29, 2022 19:15
Show Gist options
  • Save oscar230/166f48c9c8066c72bd4edbdae0ceb860 to your computer and use it in GitHub Desktop.
Save oscar230/166f48c9c8066c72bd4edbdae0ceb860 to your computer and use it in GitHub Desktop.
#!/bin/bash
echo "Starting FLAC to MP3 320kbps converter."
if ! command -v ffmpeg &> /dev/null
then
echo "Error: ffmpeg could not be found"
exit
fi
find . -name "*.flac" -exec ffmpeg -n -i '{}' -ab 320k -map_metadata 0 -id3v2_version 3 '{}'.mp3 \; -exec mv '{}' '{}'.remove \;
echo "Completed."
@oscar230
Copy link
Author

oscar230 commented Oct 29, 2022

Run with:

source <(curl -s RAW_LINK_TO_THIS_GIST)

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment