Don't echo dir. Lower sample rate

This commit is contained in:
RealStickman 2021-01-20 20:53:32 +01:00
parent a90e89c8af
commit 9c95f96d8d

View File

@ -8,25 +8,24 @@ cd "$HOME/MusikRaw"
numjobs="$1" numjobs="$1"
# get directories # get directories
#ls -d */ | awk '{gsub(/ /,"\\ ")}8' - > directories
ls -d */ > directories ls -d */ > directories
while read -r dir; do while read -r dir; do
echo "$dir" #echo "$dir"
# if there are $numjobs or more, dont spawn any new processes # if there are $numjobs or more, dont spawn any new processes
while [[ $(jobs | wc -l) -gt $numjobs ]] ; do sleep 1 ; done while [[ $(jobs | wc -l) -gt $numjobs ]] ; do sleep 1 ; done
cd "$dir" cd "$dir"
# convert m4a # convert m4a
if [[ $(ls | grep ".m4a") ]]; then if [[ $(ls | grep ".m4a") ]]; then
ffmpeg-normalize *.m4a -v -pr -c:a libopus -ext opus & ffmpeg-normalize *.m4a -v -pr -c:a libopus -ar 92 -ext opus &
fi fi
# convert flac # convert flac
if [[ $(ls | grep ".flac") ]]; then if [[ $(ls | grep ".flac") ]]; then
ffmpeg-normalize *.flac -v -pr -c:a flac -ext flac & ffmpeg-normalize *.flac -v -pr -c:a flac -ar 88.2 -ext flac &
fi fi
# convert opus # convert opus
if [[ $(ls | grep ".opus") ]]; then if [[ $(ls | grep ".opus") ]]; then
ffmpeg-normalize *.opus -v -pr -c:a libopus -ext opus & ffmpeg-normalize *.opus -v -pr -c:a libopus -ar 92 -ext opus &
fi fi
cd "$HOME/MusikRaw" cd "$HOME/MusikRaw"
# create directory # create directory