I'd like to trim silence from the end of audio1.wav and beginning of audio2.wav and concatenate them by adding silence of predefined duration?
UPDATE
Following ffmpeg command add silence in between two wav files (from answer):
ffmpeg -y -i $in_wav_0 -i $in_wav_1 -filter_complex "aevalsrc=exprs=0:d=$pause[silence], [0:a] [silence] [1:a] concat=n=3:v=0:a=1[outa]" -map [outa] $out_wav
This command trims silence from the end (from answer):
ffmpeg -i input.wav -af silenceremove=1:0:-50dB input.wav
How to combine those two to commands so that concatenation would produce fixed duration silence interval in between regardless of silence present at the end and beginning of original audio files respectively? And preferably in one command.