view organism_add_organism.xml @ 3:92407294b12e draft

planemo upload for repository https://github.com/galaxy-genome-annotation/galaxy-tools/tree/master/tools/tripal commit d21999bb3e142fd972a3338b70216989a257d5b1
author gga
date Mon, 06 Aug 2018 04:44:48 -0400
parents 56390a41953e
children 2d707e97598b
line wrap: on
line source

<?xml version="1.0"?>
<tool id="organism_add_organism" profile="16.04" name="Create an organism" version="@WRAPPER_VERSION@.0">
    <description>in Tripal</description>
    <macros>
        <import>macros.xml</import>
    </macros>
    <expand macro="requirements">
        <requirement type="package" version="1.5">jq</requirement>
    </expand>
    <expand macro="stdio"/>
    <command><![CDATA[

        @AUTH@

        tripaille organism add_organism

            #if str($description):
                --comment '$description'
            #end if

            #if $infra.use_infra:
                --infraspecific_rank '$infra.rank'
                --infraspecific_name '$infra.name'
            #end if

            '$genus'
            '$species'
            '$common'
            '$abbr'

            | jq -S . > $results
    ]]></command>
    <inputs>
        <param name="genus"
               type="text"
               label="Genus"
               help="e.g.: Homo" />

        <param name="species"
               argument="--species"
               type="text"
               label="Species"
               help="e.g.: sapiens" />

        <param name="abbr"
               type="text"
               label="Abbreviation"
               help="e.g.: H. sapiens" />

        <param name="common"
               type="text"
               label="Common name"
               help="e.g.: Human" />

        <param name="description"
               argument="--comment"
               type="text"
               label="Description"
               optional="True">
            <expand macro="sanitized"/>
        </param>

        <conditional name="infra">
            <param name="use_infra" type="boolean" checked="false" label="Specify an infraspecific rank" />
            <when value="false"></when>
            <when value="true">
                <param name="rank"
                       argument="--infraspecific_rank"
                       type="select"
                       label="Infraspecific Rank">
                    <option value="subspecies">subspecies</option>
                    <option value="varietas">varietas</option>
                    <option value="subvariety">subvariety</option>
                    <option value="forma">forma</option>
                    <option value="subforma">subforma</option>
                </param>
                <param name="name"
                       argument="--infraspecific_name"
                       type="text"
                       label="Infraspecific Name"
                       help="The infraspecific name of the new organism (e.g. a strain name)" />
            </when>
        </conditional>
    </inputs>
    <outputs>
        <data format="json" name="results" label="New Tripal organism" />
    </outputs>
    <tests>
        <test expect_failure="true">
            <param name="genus" value="Testus" />
            <param name="species" value="testum" />
            <param name="abbr" value="test" />
            <param name="common" value="test stuff" />
            <param name="common" value="My cool new test organism" />

            <expand macro="test_result" />
        </test>
        <test expect_failure="true">
            <param name="genus" value="Testus" />
            <param name="species" value="testum" />
            <param name="abbr" value="test" />
            <param name="common" value="test stuff" />
            <param name="common" value="My cool new test organism" />
            <conditional name="infra">
                <param name="use_infra" value="True" />
                <param name="rank" value="subspecies" />
                <param name="name" value="strain3" />
            </conditional>

            <expand macro="test_result" />
        </test>
    </tests>
    <help><![CDATA[
        @HELP_OVERVIEW@

        **Create Organism**

        With this tool, you can create a new organism in the Tripal/Chado database

        @HELP@
    ]]></help>
    <expand macro="citation"/>
</tool>