Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make a cook book example for string matching in WDL #15

Open
ekiernan opened this issue Dec 19, 2022 · 1 comment
Open

Make a cook book example for string matching in WDL #15

ekiernan opened this issue Dec 19, 2022 · 1 comment

Comments

@ekiernan
Copy link
Collaborator

No description provided.

@kayleemathews
Copy link
Collaborator

From Broad slack: https://broadinstitute.slack.com/archives/CESEYJW9W/p1663869404506729

From Morgan:

i think you could use sub to do this with something like
> if (sub(sample_name, "clinical", "") != sample_name) { ...
i.e. if i'm able to remove the substring i'm looking to match, it means the substring was present and the sub() output will not be the same as my original string

Jess also did this in the example script she wrote for Conditionally running different WDL tasks based on input data type using if(sub())

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants