Repository 'tabular_to_fastq'
hg clone https://toolshed.g2.bx.psu.edu/repos/devteam/tabular_to_fastq

Changeset 4:2dcfbbf9071a (2020-02-19)
Previous changeset 3:68f57cc8fad0 (2019-11-01) Next changeset 5:78fb18899c99 (2024-10-04)
Commit message:
"planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tool_collections/galaxy_sequence_utils/tabular_to_fastq commit d4ced60a941c4c4a2fe95de9c09a10086810b387"
modified:
tabular_to_fastq.py
tabular_to_fastq.xml
added:
macros.xml
b
diff -r 68f57cc8fad0 -r 2dcfbbf9071a macros.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/macros.xml Wed Feb 19 12:59:28 2020 -0500
b
@@ -0,0 +1,9 @@
+<macros>
+    <token name="@TOOL_VERSION@">1.1.5</token>
+    <xml name="requirements">
+        <requirements>
+            <requirement type="package" version="@TOOL_VERSION@">galaxy_sequence_utils</requirement>
+            <yield/>
+        </requirements>
+    </xml>>
+</macros>
b
diff -r 68f57cc8fad0 -r 2dcfbbf9071a tabular_to_fastq.py
--- a/tabular_to_fastq.py Fri Nov 01 13:27:30 2019 -0400
+++ b/tabular_to_fastq.py Wed Feb 19 12:59:28 2020 -0500
[
@@ -14,15 +14,14 @@
     max_col = max(identifier_col, sequence_col, quality_col)
     num_reads = None
     skipped_lines = 0
-    out = open(output_filename, 'w')
-    for num_reads, line in enumerate(open(input_filename)):
-        fields = line.rstrip('\n\r').split('\t')
-        if len(fields) > max_col:
-            out.write("@%s\n%s\n+\n%s\n" % (fields[identifier_col], fields[sequence_col], fields[quality_col]))
-        else:
-            skipped_lines += 1
+    with open(output_filename, 'w') as out:
+        for num_reads, line in enumerate(open(input_filename)):
+            fields = line.rstrip('\n\r').split('\t')
+            if len(fields) > max_col:
+                out.write("@%s\n%s\n+\n%s\n" % (fields[identifier_col], fields[sequence_col], fields[quality_col]))
+            else:
+                skipped_lines += 1
 
-    out.close()
     if num_reads is None:
         print("Input was empty.")
     else:
b
diff -r 68f57cc8fad0 -r 2dcfbbf9071a tabular_to_fastq.xml
--- a/tabular_to_fastq.xml Fri Nov 01 13:27:30 2019 -0400
+++ b/tabular_to_fastq.xml Wed Feb 19 12:59:28 2020 -0500
[
@@ -1,4 +1,4 @@
-<tool id="tabular_to_fastq" name="Tabular to FASTQ" version="1.1.1">
+<tool id="tabular_to_fastq" name="Tabular to FASTQ" version="@TOOL_VERSION@">
     <description>converter</description>
     <edam_topics>
         <edam_topic>topic_0622</edam_topic>
@@ -6,6 +6,12 @@
     <edam_operations>
         <edam_operation>operation_3434</edam_operation>
     </edam_operations>
+    <macros>
+        <import>macros.xml</import>
+    </macros>
+    <requirements>
+        <requirement  type="package" version="3.7">python</requirement>
+    </requirements>
     <command><![CDATA[
 python '$__tool_directory__/tabular_to_fastq.py' '$input_file' '$output_file' '$identifier' '$sequence' '$quality'
     ]]></command>