Hello David,

This is not currently possible, but will be available in the next Galaxy distribution release, currently scheduled for about 10 days from now.  You will include a tool_dependencies.xml file in your tool shed repository that looks something like the following.

<?xml version="1.0"?>
<tool_dependency>
    <set_environment version="1.0">
        <environment_variable name="JAVA_JAR_PATH" action="set_to">$INSTALL_DIR</environment_variable>
    </set_environment>
</tool_dependency>

Your tool will find the required files via the defined JAVA_JAR_PATH by using a <requirements> tag set in the tool config, something like this:

    <requirements>
        <requirement type="set_environment">JAVA_JAR_PATH </requirement>
    </requirements>

The <command> tag in the tool config would be something like this:

<command interpreter="python">
python_wrapper.py $JAVA_JAR_PATH/some_file.jar $param1 $param2...
</command>

I'm close to having this working, so if you are interested in testing before the next Galaxy dist release, let me know and I'll tell you when the Galaxy central repository has the new feature.

Thanks!

Greg Von Kuster


On Sep 12, 2012, at 1:00 PM, David Hoover wrote:

Are there any environment variables that are honored by toolshed installed tools?  I tried creating a tool that uses ${GALAXY_DATA_INDEX_DIR} or $GALAXY_HOME, then uploaded it the test toolshed, then installed it automatically.  Neither of these resolved to what I expected.  I don't want to hard-code the path in the xml tool file, but rather have a default location for other executables and jar files.  How should this best be done?

David Hoover
Helix Systems Staff
___________________________________________________________
Please keep all replies on the list by using "reply all"
in your mail client.  To manage your subscriptions to this
and other Galaxy lists, please use the interface at:

 http://lists.bx.psu.edu/