Mercurial > repos > galaxyp > openms_masscalculator
diff MassCalculator.xml @ 9:ff18cb79cdd2 draft
"planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit 020906fb54bde7fc143c356f41975c378a741315"
author | galaxyp |
---|---|
date | Wed, 09 Sep 2020 12:46:33 +0000 |
parents | b3d5b4861942 |
children | 65c6e741ddf3 |
line wrap: on
line diff
--- a/MassCalculator.xml Fri May 17 09:47:58 2019 -0400 +++ b/MassCalculator.xml Wed Sep 09 12:46:33 2020 +0000 @@ -1,103 +1,76 @@ <?xml version='1.0' encoding='UTF-8'?> <!--This is a configuration file for the integration of a tools into Galaxy (https://galaxyproject.org/). This file was automatically generated using CTDConverter.--> <!--Proposed Tool Section: [Utilities]--> -<tool id="MassCalculator" name="MassCalculator" version="2.3.0"> +<tool id="MassCalculator" name="MassCalculator" version="@TOOL_VERSION@+galaxy@GALAXY_VERSION@" profile="20.05"> <description>Calculates masses and mass-to-charge ratios of peptide sequences</description> <macros> <token name="@EXECUTABLE@">MassCalculator</token> <import>macros.xml</import> + <import>macros_autotest.xml</import> + <import>macros_test.xml</import> </macros> - <expand macro="references"/> - <expand macro="stdio"/> <expand macro="requirements"/> - <command detect_errors="aggressive"><![CDATA[MassCalculator - -#if $param_in: - -in $param_in -#end if + <expand macro="stdio"/> + <command detect_errors="exit_code"><![CDATA[@QUOTE_FOO@ +@EXT_FOO@ +#import re -#if $rep_param_in_seq: --in_seq - #for token in $rep_param_in_seq: - #if " " in str(token): - "$token.param_in_seq" - #else - $token.param_in_seq - #end if - #end for +## Preprocessing +#if $in: + mkdir in && + ln -s '$in' 'in/${re.sub("[^\w\-_]", "_", $in.element_identifier)}.$gxy2omsext($in.ext)' && #end if -#if $param_out: - -out $param_out +#if "out_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + mkdir out && #end if -#if $rep_param_charge: --charge - #for token in $rep_param_charge: - #if " " in str(token): - "$token.param_charge" - #else - $token.param_charge - #end if - #end for +## Main program call + +set -o pipefail && +@EXECUTABLE@ -write_ctd ./ && +python3 '$__tool_directory__/fill_ctd.py' '@EXECUTABLE@.ctd' '$args_json' '$hardcoded_json' && +@EXECUTABLE@ -ini @EXECUTABLE@.ctd +#if $in: + -in + 'in/${re.sub("[^\w\-_]", "_", $in.element_identifier)}.$gxy2omsext($in.ext)' #end if -#if $param_format: - -format - #if " " in str($param_format): - "$param_format" - #else - $param_format - #end if +#if "out_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + -out + 'out/output.${gxy2omsext("txt")}' #end if -#if $param_average_mass: - -average_mass -#end if -#if $param_fragment_type: - -fragment_type - #if " " in str($param_fragment_type): - "$param_fragment_type" - #else - $param_fragment_type - #end if +#if len(str($OPTIONAL_OUTPUTS).split(',')) == 0 + | tee '$stdout' #end if -#if $param_separator: - -separator "$param_separator" + +## Postprocessing +#if "out_FLAG" in str($OPTIONAL_OUTPUTS).split(',') + && mv 'out/output.${gxy2omsext("txt")}' '$out' #end if -#if $adv_opts.adv_opts_selector=='advanced': - #if $adv_opts.param_force: - -force -#end if -#end if -]]></command> +#if "ctd_out_FLAG" in $OPTIONAL_OUTPUTS + && mv '@EXECUTABLE@.ctd' '$ctd_out' +#end if]]></command> + <configfiles> + <inputs name="args_json" data_style="paths"/> + <configfile name="hardcoded_json"><![CDATA[{"log": "log.txt", "threads": "\${GALAXY_SLOTS:-1}", "no_progress": true}]]></configfile> + </configfiles> <inputs> - <param name="param_in" type="data" format="txt" optional="True" label="Input file with peptide sequences and optionally charge numbers (mutually exclusive to 'in_seq')" help="(-in) "/> - <repeat name="rep_param_in_seq" min="0" title="param_in_seq"> - <param name="param_in_seq" type="text" size="30" label="List of peptide sequences (mutually exclusive to 'in')" help="(-in_seq) "> - <sanitizer> - <valid initial="string.printable"> - <remove value="'"/> - <remove value="""/> - </valid> - </sanitizer> - </param> - </repeat> - <repeat name="rep_param_charge" min="0" max="1" title="param_charge"> - <param name="param_charge" type="text" size="30" value="0" label="List of charge states; required if 'in_seq' is given" help="(-charge) "> - <sanitizer> - <valid initial="string.printable"> - <remove value="'"/> - <remove value="""/> - </valid> - </sanitizer> - </param> - </repeat> - <param name="param_format" display="radio" type="select" optional="False" value="list" label="Output format ('list': human-readable list, 'table': CSV-like table, 'mass_only': mass values only, 'mz_only': m/z values only)" help="(-format) "> + <param name="in" argument="-in" type="data" format="txt" optional="true" label="Input file with peptide sequences and optionally charge numbers (mutually exclusive to 'in_seq')" help=" select txt data sets(s)"/> + <param name="in_seq" argument="-in_seq" type="text" optional="true" value="" label="List of peptide sequences (mutually exclusive to 'in')" help=" (space separated list, in order to allow for spaces in list items surround them by single quotes)"> + <expand macro="list_string_val"/> + <expand macro="list_string_san"/> + </param> + <param name="charge" argument="-charge" type="text" optional="true" value="0" label="List of charge states; required if 'in_seq' is given" help=" (space separated list, in order to allow for spaces in list items surround them by single quotes)"> + <expand macro="list_integer_valsan"/> + </param> + <param name="format" argument="-format" display="radio" type="select" optional="false" label="Output format ('list': human-readable list, 'table': CSV-like table, 'mass_only': mass values only, 'mz_only': m/z values only)" help=""> <option value="list" selected="true">list</option> <option value="table">table</option> <option value="mass_only">mass_only</option> <option value="mz_only">mz_only</option> + <expand macro="list_string_san"/> </param> - <param name="param_average_mass" display="radio" type="boolean" truevalue="-average_mass" falsevalue="" checked="false" optional="True" label="Compute average (instead of monoisotopic) peptide masses" help="(-average_mass) "/> - <param name="param_fragment_type" type="select" optional="False" value="full" label="For what type of sequence/fragment the mass should be computed" help="(-fragment_type) "> + <param name="average_mass" argument="-average_mass" type="boolean" truevalue="true" falsevalue="false" checked="false" label="Compute average (instead of monoisotopic) peptide masses" help=""/> + <param name="fragment_type" argument="-fragment_type" type="select" optional="false" label="For what type of sequence/fragment the mass should be computed" help=""> <option value="full" selected="true">full</option> <option value="internal">internal</option> <option value="N-terminal">N-terminal</option> @@ -108,24 +81,40 @@ <option value="x-ion">x-ion</option> <option value="y-ion">y-ion</option> <option value="z-ion">z-ion</option> + <expand macro="list_string_san"/> </param> - <param name="param_separator" type="text" size="30" label="Field separator for 'table' output format; by default, the 'tab' character is used" help="(-separator) "> - <sanitizer> - <valid initial="string.printable"> - <remove value="'"/> - <remove value="""/> - </valid> - </sanitizer> + <param name="separator" argument="-separator" type="text" optional="true" value="" label="Field separator for 'table' output format; by default, the 'tab' character is used" help=""> + <expand macro="list_string_san"/> </param> - <expand macro="advanced_options"> - <param name="param_force" display="radio" type="boolean" truevalue="-force" falsevalue="" checked="false" optional="True" label="Overwrite tool specific checks" help="(-force) "/> + <expand macro="adv_opts_macro"> + <param name="force" argument="-force" type="boolean" truevalue="true" falsevalue="false" checked="false" label="Overwrite tool specific checks" help=""/> + <param name="test" argument="-test" type="hidden" optional="true" value="False" label="Enables the test mode (needed for internal use only)" help=""> + <expand macro="list_string_san"/> + </param> </expand> + <param name="OPTIONAL_OUTPUTS" type="select" multiple="true" label="Optional outputs" optional="false"> + <option value="out_FLAG">out (Enables the test mode (needed for internal use only))</option> + <option value="ctd_out_FLAG">Output used ctd (ini) configuration file</option> + </param> </inputs> <outputs> - <data name="param_out" format="txt"/> + <data name="out" label="${tool.name} on ${on_string}: out" format="txt"> + <filter>OPTIONAL_OUTPUTS is not None and "out_FLAG" in OPTIONAL_OUTPUTS</filter> + </data> + <data name="stdout" format="txt" label="${tool.name} on ${on_string}: stdout"> + <filter>OPTIONAL_OUTPUTS is None</filter> + </data> + <data name="ctd_out" format="xml" label="${tool.name} on ${on_string}: ctd"> + <filter>OPTIONAL_OUTPUTS is not None and "ctd_out_FLAG" in OPTIONAL_OUTPUTS</filter> + </data> </outputs> - <help>Calculates masses and mass-to-charge ratios of peptide sequences + <tests> + <expand macro="autotest_MassCalculator"/> + <expand macro="manutest_MassCalculator"/> + </tests> + <help><![CDATA[Calculates masses and mass-to-charge ratios of peptide sequences -For more information, visit https://abibuilder.informatik.uni-tuebingen.de/archive/openms/Documentation/release/2.3.0/html/UTILS_MassCalculator.html</help> +For more information, visit http://www.openms.de/documentation/UTILS_MassCalculator.html]]></help> + <expand macro="references"/> </tool>