RFE: would be nice to have richer set of operators (or std library funcs) for Array type #89

Open
noblem opened this Issue Feb 14, 2017 · 0 comments

Comments

Projects
None yet
1 participant

noblem commented Feb 14, 2017 edited

I would like to be able to get a list of 3 kinds of files in a directory

*.png
*.txt
*.html

and store this list into a single output variable. I know the glob() function can be used to find each type, but that means 3 glob() invocations in the output{} section of my WDL, and there is no way to paste them together.

I suppose I could do "ls *.png *.txt *.html >> outputs.lst" in the command{} section, and then in my output{} section do Array outputs = read_lines("outputs.lst").

But it would be cleaner to be able to do something like

Array[File] = glob(".png") + glob(".txt") + glob(.html")

or

Array[File] = concat( glob(".png"), glob(".txt"), glob(*.html"))

or variants.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment