From f21352ba596f83b1ac410f18bd01e5980ce2ddbe Mon Sep 17 00:00:00 2001 From: Edmund Miller Date: Mon, 29 Jul 2024 14:46:31 -0500 Subject: [PATCH] Revert "test: Try hard coding the example file?" This reverts commit 2826ed4d16d867bdc2705752a4e8a29ffb80d144. --- examples/manual.fa | 2 -- main.nf | 2 +- modules/primer3_calc/main.nf | 2 +- modules/primer3_conf/main.nf | 25 +++++++++++++------------ nextflow.config | 6 +++--- 5 files changed, 18 insertions(+), 19 deletions(-) delete mode 100644 examples/manual.fa diff --git a/examples/manual.fa b/examples/manual.fa deleted file mode 100644 index e866202..0000000 --- a/examples/manual.fa +++ /dev/null @@ -1,2 +0,0 @@ ->example -GTAGTCAGTAGACNATGACNACTGACGATGCAGACNACACACACACACACAGCACACAGGTATTAGTGGGCCATTCGATCCCGACCCAAATCGATAGCTACGATGACG diff --git a/main.nf b/main.nf index 6168934..93869d4 100644 --- a/main.nf +++ b/main.nf @@ -15,6 +15,6 @@ workflow { primer3_conf(target,ref) primer3_index(ref) - primer3_calc(primer3_conf.out) + primer3_calc(primer3_conf.out,primer3_index.out) primer3_results2fasta(primer3_calc.out) } diff --git a/modules/primer3_calc/main.nf b/modules/primer3_calc/main.nf index 4bb5e31..6f08c88 100644 --- a/modules/primer3_calc/main.nf +++ b/modules/primer3_calc/main.nf @@ -6,7 +6,7 @@ process primer3_calc { input: path conf - // path kmer_lists, stageAs: 'kmer_lists/*' + path kmer_lists, stageAs: 'kmer_lists/*' output: path "*primer3.txt" diff --git a/modules/primer3_conf/main.nf b/modules/primer3_conf/main.nf index 14fa9e8..485b300 100644 --- a/modules/primer3_conf/main.nf +++ b/modules/primer3_conf/main.nf @@ -5,7 +5,7 @@ process primer3_conf { input: path target - path fasta // TODO Cut this out + path fasta output: path "custom_primer3.conf" @@ -23,21 +23,22 @@ process primer3_conf { ## ## - echo "SEQUENCE_ID=example - SEQUENCE_TEMPLATE=GTAGTCAGTAGACNATGACNACTGACGATGCAGACNACACACACACACACAGCACACAGGTATTAGTGGGCCATTCGATCCCGACCCAAATCGATAGCTACGATGACG - SEQUENCE_TARGET=37,21 + echo "SEQUENCE_ID=$(seqkit fx2tab !{target} | cut -f 1) + SEQUENCE_TEMPLATE=$(seqkit fx2tab !{target} | cut -f 2) + SEQUENCE_TARGET=50000,20 + SEQUENCE_EXCLUDED_REGION=49965,70 PRIMER_TASK=generic PRIMER_PICK_LEFT_PRIMER=1 - PRIMER_PICK_INTERNAL_OLIGO=1 + PRIMER_PICK_INTERNAL_OLIGO=0 PRIMER_PICK_RIGHT_PRIMER=1 - PRIMER_OPT_SIZE=18 - PRIMER_MIN_SIZE=15 - PRIMER_MAX_SIZE=21 - PRIMER_MAX_NS_ACCEPTED=1 - PRIMER_PRODUCT_SIZE_RANGE=75-100 - P3_FILE_FLAG=1 - SEQUENCE_INTERNAL_EXCLUDED_REGION=37,21 + PRIMER_OPT_SIZE=20 + PRIMER_MIN_SIZE=18 + PRIMER_MAX_SIZE=22 + PRIMER_PRODUCT_SIZE_RANGE=75-500 PRIMER_EXPLAIN_FLAG=1 + PRIMER_MASK_TEMPLATE=1 + PRIMER_MASK_KMERLIST_PREFIX=!{fasta} + PRIMER_MASK_KMERLIST_PATH=./kmer_lists/ =" > custom_primer3.conf ''' } diff --git a/nextflow.config b/nextflow.config index 18728bf..55f8946 100644 --- a/nextflow.config +++ b/nextflow.config @@ -7,10 +7,10 @@ docker.enabled = true wave.enabled = true profiles { - example { + test { params { - fasta = "${projectDir}/examples/manual.fa" - targetseq = "GTAGTCAGTAGACNATGACNACTGACGATGCAGACNACACACACACACACAGCACACAGGTATTAGTGGGCCATTCGATCCCGACCCAAATCGATAGCTACGATGACG" + fasta = "${projectDir}/examples/example.fa" + targetseq = "ATGGGAGGAGAAGGGTATCGCGG" } } }