Files
G4G0-1/Semester 2/Computer Systems Internals & Linux/Week 2/sounds.sh

14 lines
338 B
Bash

#!/bin/bash
file=1;
for audio in media/*.mp3; do
if [ $audio != "media/footsteps_forest_01.mp3" ]; then
echo Processing $audio
filename="00$file"
filename=${filename:(-3)}
sox $audio temp.wav silence 1 0 0
sox media/footsteps_forest_01.mp3 temp.wav -C 128 $filename.mp3
rm temp.wav
let file=file+1
fi
done