cherry picked "* New CGG export scripts template" commit (https://github.com/webdetails/cde/commit/219f9e88905d72a76630f86efb8e5bd088192550) and conflicts resolved