diff aws_sra.xml @ 7:3529ce6bcde7 draft

planemo upload for repository https://github.com/CFSAN-Biostatistics/galaxytrakr-tools commit 74cea66080315c44e81547de5fe02f046bcaa1f0
author galaxytrakr
date Mon, 23 Mar 2026 18:32:46 +0000
parents 8c60cd4c0ca7
children ef51d44623c2
line wrap: on
line diff
--- a/aws_sra.xml	Mon Mar 23 18:17:47 2026 +0000
+++ b/aws_sra.xml	Mon Mar 23 18:32:46 2026 +0000
@@ -1,4 +1,4 @@
-<tool id="aws_sra" name="NCBI SRA AWS Fetch" version="0.3.0+gt_0.6" profile="23.0">
+<tool id="aws_sra" name="NCBI SRA AWS Fetch" version="0.3.0+gt_0.7" profile="23.0">
     <description>Fetch SRA data files from NCBI's public AWS S3 buckets</description>
 
     <requirements>
@@ -49,27 +49,24 @@
         #elif $action.mode == 'fastq_dump'
             #set $acc = $action.accession.strip()
 
-            ## 1. Download the .sra file from S3
+            ## 1. Download the file from S3 
             mkdir -p sra_cache &&
-            aws s3 cp
-                --no-sign-request
-                '${s3_base}/sra/${acc}/${acc}.sra'
-                ./sra_cache/${acc}.sra &&
+            aws s3 cp \
+                --no-sign-request \
+                '${s3_base}/sra/${acc}/${acc}' \
+                ./sra_cache/${acc} &&
 
-            ## 2. Convert with fasterq-dump --split-files.
-            ##    Paired runs  → <acc>_1.fastq + <acc>_2.fastq
-            ##    Single runs  → <acc>.fastq   (no _1/_2 suffix)
-            ##    We always use --split-files; single-end runs simply produce one file.
+            ## 2. Convert with fasterq-dump (CORRECTED: uses extensionless file)
             mkdir -p fastq_out &&
-            fasterq-dump
-                ./sra_cache/${acc}.sra
-                --outdir ./fastq_out
-                --temp .
-                --threads \${GALAXY_SLOTS:-4}
+            fasterq-dump \
+                ./sra_cache/${acc} \
+                --outdir ./fastq_out \
+                --temp . \
+                --threads \${GALAXY_SLOTS:-4} \
                 --split-files
             &&
 
-            ## 3. Compress with pigz (fasterq-dump does not gzip natively)
+            ## 3. Compress with pigz
             pigz -p \${GALAXY_SLOTS:-4} ./fastq_out/*.fastq &&
 
             ## 4. Stage outputs
@@ -147,7 +144,7 @@
                 <param name="accession" type="text" label="SRA Accession"
                        help="SRA run accession to fetch and convert, e.g. SRR000001. Must be present in sra-pub-run-odp.">
                     <validator type="empty_field" message="An SRA accession is required."/>     
-                    <validator type="regex" message="Must be a valid SRA run accession (SRR, ERR, or DRR followed by digits).">^\[SED\]RR\[0-9\]+$</validator>
+                    <validator type="regex" message="Must be a valid SRA run accession (SRR, ERR, or DRR followed by digits).">^[SED]RR[0-9]+$</validator>
                 </param>
                 <param name="layout" type="select" label="Read layout"
                        help="Paired-end produces two datasets labelled accession_1 and accession_2. Single-end produces one dataset. Check the SRA record to confirm layout before running.">