We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
if defined(argument)
For example, say I wanted to generate a WDL wrapper for the --lines flag for the unix tool head:
--lines
head
from wdlgen import Task inp = Task.Command.CommandInput( name='lines', prefix='--lines', optional=True ) print(inp.get_string())
This generates:
~{if defined(lines) then ("--lines " + '"' + lines + '"') else ""}
However, what I want, based on this part of the spec is the much neater:
${"--lines=" + lines}
Or, including quotes:
${'--lines="' + lines + '"'}
How can I do this?
The text was updated successfully, but these errors were encountered:
The optional scalar values should definitely simplify to:
I didn't realise string + null + string => null and hence totally empty, hence:
And should be simplified as you suggested to:
I'll issue a PR for this soon.
Sorry, something went wrong.
(Future readers) Please see #4 (comment) for continuation of this.
Successfully merging a pull request may close this issue.
For example, say I wanted to generate a WDL wrapper for the
--lines
flag for the unix toolhead
:This generates:
However, what I want, based on this part of the spec is the much neater:
Or, including quotes:
How can I do this?
The text was updated successfully, but these errors were encountered: