From 1223614e15f766d52f756b9d8965d87572bc2a12 Mon Sep 17 00:00:00 2001 From: MaxUlysse Date: Tue, 14 Jul 2020 17:10:23 +0200 Subject: [PATCH] add modules for bwa-mem2 --- tools/bwa-mem2/index/main.nf | 16 ++++++++++++++ tools/bwa-mem2/index/meta.yml | 26 +++++++++++++++++++++++ tools/bwa-mem2/index/test/main.nf | 16 ++++++++++++++ tools/bwa-mem2/index/test/nextflow.config | 2 ++ 4 files changed, 60 insertions(+) create mode 100644 tools/bwa-mem2/index/main.nf create mode 100644 tools/bwa-mem2/index/meta.yml create mode 100644 tools/bwa-mem2/index/test/main.nf create mode 100644 tools/bwa-mem2/index/test/nextflow.config diff --git a/tools/bwa-mem2/index/main.nf b/tools/bwa-mem2/index/main.nf new file mode 100644 index 00000000..dbc8f40e --- /dev/null +++ b/tools/bwa-mem2/index/main.nf @@ -0,0 +1,16 @@ +process bwa-mem2_index { + tag {fasta} + + container 'quay.io/biocontainers/bwa-mem2:2.0--he513fc3_0' + + input: + path(fasta) + + output: + path("${fasta}.*") + + script: + """ + bwa-mem2 index ${fasta} + """ +} \ No newline at end of file diff --git a/tools/bwa-mem2/index/meta.yml b/tools/bwa-mem2/index/meta.yml new file mode 100644 index 00000000..8d0d8ab9 --- /dev/null +++ b/tools/bwa-mem2/index/meta.yml @@ -0,0 +1,26 @@ +name: bwa-mem2 index +description: create indexes for BWA from a fasta file +keywords: + - index +tools: + - bwa: + description: | + Bwa-mem2 is the next version of the bwa-mem algorithm in bwa. + It produces alignment identical to bwa and is ~1.3-3.1x faster depending on the use-case, dataset and the running machine. + homepage: https://github.com/bwa-mem2/bwa-mem2 + documentation: https://github.com/bwa-mem2/bwa-mem2 + arxiv: arXiv:1303.3997 +input: + - + - input: + type: file + description: Input fasta file + pattern: *.{fasta,fa} +output: + - + - index: + type: file + description: bwa indexes file + pattern: *.{fasta,fa}.{amb,ann,bwt,pac,sa} +authors: + - @maxulysse \ No newline at end of file diff --git a/tools/bwa-mem2/index/test/main.nf b/tools/bwa-mem2/index/test/main.nf new file mode 100644 index 00000000..6acb4d61 --- /dev/null +++ b/tools/bwa-mem2/index/test/main.nf @@ -0,0 +1,16 @@ +#!/usr/bin/env nextflow +nextflow.preview.dsl = 2 +include '../../../nf-core/module_testing/check_process_outputs.nf' params(params) +include '../main.nf' params(params) + +// Define input channels +input = '../../../test-datasets/tools/bwa/index/input/reference.fasta' +Channel + .from(input) + .set { ch_input } + +// Run the workflow +workflow { + fastqc(ch_input) + // .check_output() +} diff --git a/tools/bwa-mem2/index/test/nextflow.config b/tools/bwa-mem2/index/test/nextflow.config new file mode 100644 index 00000000..c137a138 --- /dev/null +++ b/tools/bwa-mem2/index/test/nextflow.config @@ -0,0 +1,2 @@ +docker.enabled = true +params.outdir = './results'