I'm using a locally installed tool in my tool shed (it's picard) and I want to pass it picard's install directory.
When installing picard through galaxy it sets up special galaxy-only environment variables using the tool_dependencies.xml file which each picard tool xml wrapper references. I want to edit one of these variables (JAVA_JAR_PATH
) and assign it my own picard install's path. But if I just edit it from:
<action type="set_environment">
<environment_variable name="JAVA_JAR_PATH" action="set_to">$INSTAL_DIR</environment_variable>
</action>
to
<action type="set_environment">
<environment_variable name="JAVA_JAR_PATH" action="set_to">"/opt/mydir/picard-tools-1.79/"
</environment_variable>
</action>
it shows up as empty when I call it in the xml wrapper. How can I set this variable so that picard's xml tools can access it? Like:
<command interpreter="python"> picard_wrapper.py \$JAVA_JAR_PATH/MarkDuplicates.jar </command>
I have to use an older custom picard because I have to replicate some exact data, otherwise I'd use the Tool Shed version certainly.
If I'm understanding you right you're saying I should set JAVA_JAR_PATH in every file that uses it? I'd prefer if I could just set it once somewhere. Many files source it and it may need changing a lot. I'll try moving the
set_environment
command from the dependency file to one of the scripts and see if that works.No you can set it in .bashrc or elsewhere, but it needs to be visible for galaxy and your dependency must be deinstalled. What the Tool Shed did is sourcing the path to picard (the tool shed picard) in a new env.sh file and that is sourced before the tool is executed. You need to deactivate it (with deinstalling the dependency) and using your own JAVA_JAR_PATH (set in .bashrc).