view data_manager/bowtie2_index_builder.xml @ 0:a7169e7254c1 draft default tip

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/data_managers/data_manager_bowtie2_index_builder commit fd18bdf0c66a87e5ffda1dcba60d8ef9bc73d1bf-dirty
author wolma
date Mon, 15 Jul 2019 09:13:47 -0400
parents
children
line wrap: on
line source

<tool id="bowtie2_index_builder_data_manager" name="Bowtie2 index" tool_type="manage_data" version="@WRAPPER_VERSION@+galaxy1" profile="18.09">
    <description>builder</description>
    <requirements>
        <requirement type="package" version="5.1.1">pyyaml</requirement>
        <requirement type="package" version="@DEPENDENCY_VERSION@">bowtie2</requirement>
        <!--
        The future:
        conda-install data managers just like regular dependencies?
        <requirement type="package" version="@WRAPPER_VERSION@">data_manager_bowtie2
        -->
    </requirements>
    <macros>
        <token name="@DEPENDENCY_VERSION@">2.3.4.3</token>
        <token name="@WRAPPER_VERSION@">2.3.4.3</token>
        <token name="@SET_DEFAULTS@">
## use the ref genome's ID as default for the index ID
#if not str($sequence_id).strip():
  #set $sequence_id = $all_fasta_source.fields.dbkey
#end if
## use the ref genome's name as default for the index name
#if not str($sequence_name).strip():
  #set $sequence_name = $all_fasta_source.fields.name
#end if
        </token>
    </macros>
    <configfiles>
        <configfile name="metadata_yaml">
@SET_DEFAULTS@
source: '${all_fasta_source.fields.path}'
dbkey: '${all_fasta_source.fields.dbkey}'
description: '${all_fasta_source.fields.name}'
id: '$sequence_id'
name: '$sequence_name'
version: 2
        </configfile>
        <configfile name="data_table_json">
@SET_DEFAULTS@
{
    "data_tables": {
        "bowtie2_indexes": [
            {
                "value": "$sequence_id",
                "dbkey": "$all_fasta_source.fields.dbkey",
                "name": "$sequence_name",
                "path": "$sequence_id"
            }
        ]
    #if $tophat2:
        ,
        "tophat2_indexes": [
            {
                "value": "$sequence_id",
                "dbkey": "$all_fasta_source.fields.dbkey",
                "name": "$sequence_name",
                "path": "$sequence_id"
            }
        ]
    #end if
    }
}
        </configfile>
    </configfiles>
    <command detect_errors="exit_code"><![CDATA[
python '$__tool_directory__/bowtie2_index_builder.py'
--target-directory '${out_file.extra_files_path}' '$metadata_yaml'
&&
mv '$metadata_yaml' $meta_file
&&
mv '$data_table_json' $out_file
    ]]></command>
    <inputs>
        <param name="all_fasta_source" type="select" label="Source FASTA Sequence">
            <options from_data_table="all_fasta"/>
        </param>
        <param name="sequence_name" type="text" value="" label="Name of sequence" />
        <param name="sequence_id" type="text" value="" label="ID for sequence" />
        <param name="tophat2" type="boolean" truevalue="tophat2_indexes" falsevalue="" checked="True" label="Also make available for TopHat" help="Adds values to tophat2_indexes tool data table" />
    </inputs>
    <outputs>
        <data name="meta_file" format="txt"/>
        <data name="out_file" format="data_manager_json"/>
    </outputs>
    <tests>
        <test>
            <param name="all_fasta_source" value="phiX174"/>
            <output name="out_file" value="bowtie2_data_manager.json"/>
        </test>
    </tests>

    <help>
.. class:: infomark

**Notice:** If you leave name, description, or id blank, it will be generated automatically.
    </help>
</tool>