mirror of
https://github.com/MillironX/nf-core_modules.git
synced 2024-12-22 11:08:17 +00:00
adding upzip
This commit is contained in:
parent
60793adea2
commit
f1fc7fc38e
7 changed files with 71 additions and 32 deletions
|
@ -26,13 +26,24 @@ process GAMMA {
|
||||||
script:
|
script:
|
||||||
def args = task.ext.args ?: ''
|
def args = task.ext.args ?: ''
|
||||||
def prefix = task.ext.prefix ?: "${meta.id}"
|
def prefix = task.ext.prefix ?: "${meta.id}"
|
||||||
|
|
||||||
"""
|
"""
|
||||||
|
if [[ ${fasta} == *.gz ]]
|
||||||
|
then
|
||||||
|
FNAME=\$(basename ${fasta} .gz)
|
||||||
|
gunzip -f ${fasta}
|
||||||
|
GAMMA.py \\
|
||||||
|
$args \\
|
||||||
|
"\${FNAME}" \\
|
||||||
|
$db \\
|
||||||
|
$prefix
|
||||||
|
else
|
||||||
GAMMA.py \\
|
GAMMA.py \\
|
||||||
$args \\
|
$args \\
|
||||||
$fasta \\
|
$fasta \\
|
||||||
$db \\
|
$db \\
|
||||||
$prefix
|
$prefix
|
||||||
|
fi
|
||||||
cat <<-END_VERSIONS > versions.yml
|
cat <<-END_VERSIONS > versions.yml
|
||||||
"${task.process}":
|
"${task.process}":
|
||||||
gamma: $VERSION
|
gamma: $VERSION
|
29
tests/modules/gamma/gamma/main.nf
Normal file
29
tests/modules/gamma/gamma/main.nf
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
#!/usr/bin/env nextflow
|
||||||
|
|
||||||
|
nextflow.enable.dsl = 2
|
||||||
|
|
||||||
|
include { GAMMA } from '../../../../modules/gamma/gamma/main.nf'
|
||||||
|
|
||||||
|
workflow test_unzip {
|
||||||
|
|
||||||
|
input = [
|
||||||
|
[ id:'test', single_end:false ], // meta map
|
||||||
|
file(params.test_data['bacteroides_fragilis']['illumina']['test1_contigs_fa_gz'], checkIfExists: true),
|
||||||
|
]
|
||||||
|
|
||||||
|
db = [ file("https://raw.githubusercontent.com/nf-core/test-datasets/modules/data/delete_me/srst2/ResGANNCBI_20210507_srst2.fasta", checkIfExists: true), ]
|
||||||
|
|
||||||
|
GAMMA ( input, db )
|
||||||
|
}
|
||||||
|
|
||||||
|
workflow test_gamma {
|
||||||
|
|
||||||
|
input = [
|
||||||
|
[ id:'test', single_end:false ], // meta map
|
||||||
|
file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true)
|
||||||
|
]
|
||||||
|
|
||||||
|
db = [ file(params.test_data['sarscov2']['genome']['transcriptome_fasta'], checkIfExists: true) ]
|
||||||
|
|
||||||
|
GAMMA ( input, db )
|
||||||
|
}
|
29
tests/modules/gamma/gamma/test.yml
Normal file
29
tests/modules/gamma/gamma/test.yml
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
- name: gamma gamma test_unzip
|
||||||
|
command: nextflow run tests/modules/gamma/gamma -entry test_unzip -c tests/config/nextflow.config
|
||||||
|
tags:
|
||||||
|
- gamma/gamma
|
||||||
|
- gamma
|
||||||
|
files:
|
||||||
|
- path: /tmp/tmppm1ybfln/gamma/test.fasta
|
||||||
|
md5sum: 5b3b831d863fffaa3410a9ee7bfa12ce
|
||||||
|
- path: /tmp/tmppm1ybfln/gamma/test.gamma
|
||||||
|
md5sum: 46165a89e10b7315d3a9b0aa6c561626
|
||||||
|
- path: /tmp/tmppm1ybfln/gamma/test.psl
|
||||||
|
md5sum: f489ce4602ddbcb692d5781ee3fbf449
|
||||||
|
- path: /tmp/tmppm1ybfln/gamma/versions.yml
|
||||||
|
md5sum: ad23c3ec60663598543cbe8bc74bc4ab
|
||||||
|
|
||||||
|
- name: gamma gamma test_gamma
|
||||||
|
command: nextflow run tests/modules/gamma/gamma -entry test_gamma -c tests/config/nextflow.config
|
||||||
|
tags:
|
||||||
|
- gamma/gamma
|
||||||
|
- gamma
|
||||||
|
files:
|
||||||
|
- path: /tmp/tmpw3chm6da/gamma/test.fasta
|
||||||
|
md5sum: df37b48466181311e0a679f3c5878484
|
||||||
|
- path: /tmp/tmpw3chm6da/gamma/test.gamma
|
||||||
|
md5sum: 3256708fa517a65ed01d99e0e3c762ae
|
||||||
|
- path: /tmp/tmpw3chm6da/gamma/test.psl
|
||||||
|
md5sum: 162a2757ed3b167ae1e0cdb24213f940
|
||||||
|
- path: /tmp/tmpw3chm6da/gamma/versions.yml
|
||||||
|
md5sum: 3fefb5b46c94993362243c5f9a472057
|
|
@ -1,17 +0,0 @@
|
||||||
#!/usr/bin/env nextflow
|
|
||||||
|
|
||||||
nextflow.enable.dsl = 2
|
|
||||||
|
|
||||||
include { GAMMA } from '../../../modules/gamma/main.nf'
|
|
||||||
|
|
||||||
workflow test_gamma {
|
|
||||||
|
|
||||||
input = [
|
|
||||||
[ id:'test', single_end:false ], // meta map
|
|
||||||
file(params.test_data['sarscov2']['genome']['genome_fasta'], checkIfExists: true)
|
|
||||||
]
|
|
||||||
|
|
||||||
db = [ file(params.test_data['sarscov2']['genome']['transcriptome_fasta'], checkIfExists: true) ]
|
|
||||||
|
|
||||||
GAMMA ( input, db )
|
|
||||||
}
|
|
|
@ -1,13 +0,0 @@
|
||||||
- name: gamma test_gamma
|
|
||||||
command: nextflow run tests/modules/gamma -entry test_gamma -c tests/config/nextflow.config
|
|
||||||
tags:
|
|
||||||
- gamma
|
|
||||||
files:
|
|
||||||
- path: output/gamma/test.fasta
|
|
||||||
md5sum: df37b48466181311e0a679f3c5878484
|
|
||||||
- path: output/gamma/test.gamma
|
|
||||||
md5sum: 3256708fa517a65ed01d99e0e3c762ae
|
|
||||||
- path: output/gamma/test.psl
|
|
||||||
md5sum: 162a2757ed3b167ae1e0cdb24213f940
|
|
||||||
- path: output/gamma/versions.yml
|
|
||||||
md5sum: 3fefb5b46c94993362243c5f9a472057
|
|
Loading…
Reference in a new issue