【发布时间】:2016-05-07 16:38:52
【问题描述】:
我想使用 cwl(通用工作流语言)编写一个简单的命令包装器。例如,我想执行以下操作:
wc input.txt > input.txt.wc
wc some_folder/some_other_input > some_folder/some_other_input.wc
所以,基本上我希望代码将 .wc 放在输入文件名之后并将其用作输出文件名。我写了下面的代码,但它没有用。 (见下面的错误信息)。有人知道如何解决吗?
wc2.cwl
cwlVersion: cwl:draft-3
class: CommandLineTool
baseCommand: wc
inputs:
- id: inputfile
type: File
inputBinding:
position: 1
- id: outfilename
type: string
inputBinding:
valueFrom: ${ $(inputs.inputfile.path) + '.wc' }
outputs:
- id: outputfile
type: File
outputBinding:
glob: $(inputs.outfilename)
stdout: $(inputs.outfilename)
wc2-job1.yml
inputfile:
class: File
path: input.txt
运行
$ cwl-runner wc2.cwl wc2-job1.yml
/home/ec2-user/venv/cwl/bin/cwl-runner 1.0.20160504183010
I'm sorry, I couldn't load this CWL file, try again with --debug for more information.
mapping values are not allowed here
in "file:///home/ec2-user/cwl.examples/hello.workflow2/wc2.cwl", line 11, column 19
【问题讨论】:
标签: amazon-web-services workflow yaml