Attention:
The frontline support team will be unavailable to answer questions on April 15th and 17th 2019. We will be back soon after. Thank you for your patience and we apologize for any inconvenience!

Using wdl when output filenames depend on input filenames

Hi all,
I was wondering if there is a way to use wdl with programs that do not allow users to specify an output file.
We use a couple of bash commands to generate all the required index files for our analysis, and right now we have to manually include all index files in the .json file.

$ file=NC_011083.fasta  
$ dict_file=${file%fasta}dict
$ picard-tools CreateSequenceDictionary R=$file O=$dict_file
$ samtools faidx $file
$ bwa index $file

Generated index files:

NC_011083.dict   
NC_011083.fasta.amb  
NC_011083.fasta.bwt  
NC_011083.fasta.pac
NC_011083.fasta  
NC_011083.fasta.ann  
NC_011083.fasta.fai  
NC_011083.fasta.sa

NC_011083.dict gives the problem, since it wants to replace the extension, instead of just adding to it. Replacing the extension is of course the default behavior of many programs, how can we deal with this when using WDL?

Answers

Sign In or Register to comment.