On Sun, 2003-08-24 at 10:31, Steve Harris wrote: > On Sun, Aug 24, 2003 at 09:19:56 -0700, Mark Knecht wrote: > > I was looking for a solution that was possibly more like 'diff', > > where it finds where the differences begin in two text files even if the > > line numbers are different. When I read through the rsync description I > > didn't see that it would do that, but possibly it does. > > This script turnes a pair of wav files into a pair of text files with one > sample per line and diffs them, it is pretty simple and did the job, but > its not very efficient. I used it to check dodgy spdif cables :) > > run it with eg. "./audio-diff file1.wav file2.au" > it doesnt like float wav files though, cos it uses sox. > > audio-diff: > -- cut -- > #! > sox $1 /tmp/$$-a.dat > sox $2 /tmp/$$-b.dat > diff /tmp/$$-a.dat /tmp/$$-b.dat > rm -f /tmp/$$-a.dat /tmp/$$-b.dat > -- cut -- > > - Steve Steve, The beauty of the Linux command line! I love it! Presumably if one file had a few seconds of silence at the start of end I could just delete that by hand in vi? I don't know how far off in lines diff can handle looking for a first match, but a few seconds could end up being 100K lines... Thanks, Mark