Shortening long periods of silence

If you need to shorten the long periods of silence in an audio file automatically, you can use “sox”, the swiss army knife of audio stuff.

sox input.wav output.wav silence -l 1 0.1 1% -1 2.0 1% \
&& ffmpeg -i output.wav -codec:a libmp3lame -qscale:a 2 output.mp3

Reference: The SoX of Silence

Leave a Reply

Your email address will not be published. Required fields are marked *