Skip to content

Commit

Permalink
fix: different names for downloads to avoid name clashes (#71)
Browse files Browse the repository at this point in the history
* fix: different names for downloads to avoid name clashes

* lint: fix param prefix

* lint: deploy non-file parameter

---------

Co-authored-by: Yannic Eising <yeising@students.uni-mainz.de>
  • Loading branch information
cmeesters and yeising authored Aug 22, 2024
1 parent 1b50d39 commit 756ba5b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
4 changes: 2 additions & 2 deletions workflow/rules/quantification.smk
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ rule count_reads:
output:
tsv="counts/{sample}_salmon/quant.sf",
params:
tsv_dir="counts/{sample}_salmon",
outdir=lambda wildcards, ouput: output[0][:-9],
libtype=config["salmon_libtype"],
log:
"logs/salmon/{sample}.log",
Expand All @@ -18,7 +18,7 @@ rule count_reads:
shell:
"""
salmon --no-version-check quant --ont -p {resources.cpus_per_task} \
-t {input.trs} -l {params.libtype} -a {input.bam} -o {params.tsv_dir} 2> {log}
-t {input.trs} -l {params.libtype} -a {input.bam} -o {params.outdir} 2> {log}
"""


Expand Down
12 changes: 6 additions & 6 deletions workflow/rules/ref.smk
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ rule get_genome:
"../envs/env.yml"
shell:
"""
curl -o data.zip https://api.ncbi.nlm.nih.gov/datasets/v2alpha/genome/accession/{params.accession}/download?include_annotation_type=GENOME_FASTA &> {log};
unzip -p data.zip ncbi_dataset/data/{params.accession}/*.fna > references/genomic.fa 2> {log};
rm data.zip &> {log}
curl -o data_genome.zip https://api.ncbi.nlm.nih.gov/datasets/v2alpha/genome/accession/{params.accession}/download?include_annotation_type=GENOME_FASTA &> {log};
unzip -p data_genome.zip ncbi_dataset/data/{params.accession}/*.fna > references/genomic.fa 2> {log};
rm data_genome.zip &> {log}
"""


Expand All @@ -31,7 +31,7 @@ rule get_annotation:
"../envs/env.yml"
shell:
"""
curl -o data.zip https://api.ncbi.nlm.nih.gov/datasets/v2alpha/genome/accession/{params.accession}/download?include_annotation_type=GENOME_GFF &> {log};
unzip -p data.zip ncbi_dataset/data/{params.accession}/*.gff > references/genomic.gff 2> {log};
rm data.zip &> {log}
curl -o data_annotation.zip https://api.ncbi.nlm.nih.gov/datasets/v2alpha/genome/accession/{params.accession}/download?include_annotation_type=GENOME_GFF &> {log};
unzip -p data_annotation.zip ncbi_dataset/data/{params.accession}/*.gff > references/genomic.gff 2> {log};
rm data_annotation.zip &> {log}
"""

0 comments on commit 756ba5b

Please sign in to comment.