How to automatically export many clips to several audio files

Hi there!
I am trying to automate an operation using python scripting with audacity :

  • I have a single track with thousands of clips
  • I want to export each clip to a single file with a numbered name
  • The 1st clip should be named “clip_1.wav”, the 2nd clip “clip_2.wav”, etc.

I think I figured out I should do a script that labels each clip and then use “File>Export other>Export labels” to export each labeled clip. Is this the right approach?

If yes, then I struggle finding commands for :

  • Counting the number of clips in my track
  • Labeling a clip with a specific name
  • Deleting all existing labels

Many thanks for your help!

This topic was automatically closed after 30 days. New replies are no longer allowed.