Re: BatchProcessing Files on Windows

Jeff Learman <[email protected]>
Newsgroups gmane.comp.audio.sox
Message-ID <CAGyjer5an_SeaPve=ZHyatJn2+bMM7N3NS64pi=GW=4wTAbm_A@mail.gmail.com>
For the first question, I'll let the devs answer, but apparently sox
doesn't batch.

For the second question, that's not a sox issue; it's a scripting
question.  What shell are you using?  For bash:

for F in *.wav ; do
    sox $F -b 8 mydir/$F
done

I'm guessing you use Windows CLI?  For that I'd use this:
https://ss64.com/nt/for2.html -- so it looks like you just need %% instead
of %, and a backslash between the dir name and the wave file name.

Jeff




On Tue, 26 May 2020 at 18:31, Nils Wallgren <[email protected]> wrote:

> I have some problems getting these things to work:
>
>
>
> 1 I want the duration of a couple of soundfiles in a directory
>
>
>
> sox --i -D kick_*.wav
>
>
>
> the name of the sound files are kick_1.wav, kick_2.wav, kick_3.wav etc
>
> but it doesn’t work with the wildcard.
>
>
>
> 2 If I want to batch process a couple of files in a directory and
> process/convert them to something else
>
> And put the processed files in a new folder, how do I do that?
>
>
>
> for %i in *.wav do sox "%i" -b 8  "n_%i" .flac
>
>
>
> (also not sure of the conversion of the files when batching)
>
>
>
> Best,
>
>
>
> Sent from Mail <https://go.microsoft.com/fwlink/?LinkId=550986> for
> Windows 10
>
>
> _______________________________________________
> Sox-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/sox-users
>

_______________________________________________
Sox-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sox-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.