Add optional versioned output directory
dfornika opened this issue · comments
The pipeline currently creates one output directory per sample and publishes all outputs there. eg:
Line 5 in 9f0e0f0
When combining this pipeline with others, it may be useful to encapsulate the outputs from this pipeline in a sub-directory that is named with the pipeline name and version.
So by default we would create outputs of this structure:
.
├── sample-01
│ ├── sample-01_alleles.csv
│ └── sample-01_sequence_type.csv
├── sample-02
│ ├── sample-02_alleles.csv
│ └── sample-02_sequence_type.csv
└── sample-03
├── sample-03_alleles.csv
└── sample-03_sequence_type.csv
...but when running with a --versioned_outdir
flag , we would produce:
.
├── sample-01
│ └── mlst-nf-v0.1-output
│ ├── sample-01_alleles.csv
│ └── sample-01_sequence_type.csv
├── sample-02
│ └── mlst-nf-v0.1-output
│ ├── sample-01_alleles.csv
│ └── sample-01_sequence_type.csv
└── sample-03
└── mlst-nf-v0.1-output
├── sample-01_alleles.csv
└── sample-01_sequence_type.csv
...then a subsequent analysis could produce similar outputs alongside:
.
├── sample-01
│ ├── mlst-nf-v0.1-output
│ │ └── sample-01_mlst.csv
│ └── routine-assembly-v0.2-output
│ ├── sample-01_bakta.gbk
│ └── sample-01_unicycler.fa
├── sample-02
│ ├── mlst-nf-v0.1-output
│ │ └── sample-02_mlst.csv
│ └── routine-assembly-v0.2-output
│ ├── sample-02_bakta.gbk
│ └── sample-02_unicycler.fa
└── sample-03
├── mlst-nf-v0.1-output
│ └── sample-03_mlst.csv
└── routine-assembly-v0.2-output
├── sample-03_bakta.gbk
└── sample-03_unicycler.fa