This script outputs a tidied minimal version of a MapRun course KML file. It assumes the file is structured as a document for the event, containing a folder that contains the course placemarks. It will not work correctly without this structure. You first Browse to select the existing KML file, check any options wanted, then select "Tidy" to create the new tidied KML file.
The "Add Styles" option will add an icon to each placemark, using icons from the MapRunners site. These are ignored by the maprun app, but may help when viewing the course in Google Earth to nudge locations.
The "Renumber" option will renumber controls in order listed from 1. This is mainly of use for scatter courses where a low number list is wanted.