Second pass. Lots of work.
[rnaseq-cwl-training.git] / answers / ep2 / main.cwl
1 # Workflow header
2 cwlVersion: v1.2
3 class: Workflow
4 label: RNAseq CWL practice workflow
5
6 # Workflow Inputs
7 inputs:
8   fq: File
9   genome: Directory
10   gtf: File
11
12 # Workflow Steps
13 steps:
14   fastqc:
15     run: bio-cwl-tools/fastqc/fastqc_2.cwl
16     in:
17       reads_file: fq
18     out: [html_file]
19
20   # Running alignment with STAR
21   STAR:
22     run: bio-cwl-tools/STAR/STAR-Align.cwl
23     in:
24       RunThreadN: {default: 4}
25       GenomeDir: genome
26       ForwardReads: fq
27       OutSAMtype: {default: BAM}
28       OutSAMunmapped: {default: Within}
29     out: [alignment]
30
31   # Running samtools
32   samtools:
33     run: bio-cwl-tools/samtools/samtools_index.cwl
34     in:
35       bam_sorted: STAR/alignment
36     out: [bam_sorted_indexed]
37
38 # Workflow Outputs
39 outputs:
40   qc_html:
41     type: File
42     outputSource: fastqc/html_file
43   bam_sorted_indexed:
44     type: File
45     outputSource: samtools/bam_sorted_indexed