Skip to content

Instantly share code, notes, and snippets.

@MisterSirCode
Last active December 23, 2022 04:31
Embed
What would you like to do?
Bulk Convert WAV to CAF and move into root directory
#!/bin/bash
shopt -s globstar
src_dir="audio"
dest_dir="audio_new"
mkdir "$dest_dir"
for f in "${src_dir}"/**/*.wav; do
name=${f##*/}
ffmpeg -i "$f" "${dest_dir}/${name%.wav}.caf"
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment