Script that writes a full pipeline shell script, given parameters and existing files