mirror of
https://github.com/galaxyproject/galaxy.git
synced 2026-09-24 16:30:27 +08:00
Add code_file example tool from Bjoern.
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
|
||||
|
||||
from galaxy.tools.parameters import DataToolParameter
|
||||
|
||||
|
||||
|
||||
def validate_input( trans, error_map, param_values, page_param_map ):
|
||||
"""
|
||||
Validates the user input, before execution.
|
||||
"""
|
||||
first = param_values['name1']
|
||||
second = param_values['name2']
|
||||
if first == second:
|
||||
error_map['name1'] = "The value names should be different."
|
||||
@@ -0,0 +1,15 @@
|
||||
<tool id="code_file" name="code_file" version="1.0.0">
|
||||
<description>code_file</description>
|
||||
<code file="code_file.py" />
|
||||
<command>cat $input1 > $output</command>
|
||||
<inputs>
|
||||
<param name="input1" type="data" label="Concatenate Dataset" />
|
||||
<param name="name1" type="text" value="FactorName" label="value one should be different than value two" />
|
||||
<param name="name2" type="text" value="FactorName" label="value one should be different than value two" />
|
||||
</inputs>
|
||||
<outputs>
|
||||
<data format="txt" name="output" />
|
||||
</outputs>
|
||||
<tests>
|
||||
</tests>
|
||||
</tool>
|
||||
@@ -3,6 +3,7 @@
|
||||
<tool file="upload.xml"/>
|
||||
<tool file="simple_constructs.xml" />
|
||||
<tool file="composite.xml" />
|
||||
<tool file="code_file.xml" />
|
||||
<tool file="disambiguate_cond.xml" />
|
||||
<tool file="multi_repeats.xml"/>
|
||||
<tool file="multi_page.xml"/>
|
||||
|
||||
Reference in New Issue
Block a user