Skip to content

How To Run Tools Install

Lucie Hutchins edited this page Apr 24, 2018 · 12 revisions

Running Tool Installs From A Command Line

Make sure you've ran the setup script and updated the "Configuration" with the correct path.

Scripts can be ran either by proving the full path to the script, or from the repos's root directory. In this tutorial we assume we are running all the scripts from the repos root.

You have the following two options to start the tools install automation

Option 1. Running the Trigger Tool Install Script

A wrapper script that calls getToolVersion.sh/setToolVersion.sh and runGetPackage.sh scripts To download and install the current version of the tool. If a second argument is specified, then it's used as the version to install. It triggers the install only if the specified tool version is not installed.

USAGE: ./trigger_tool_install.sh tool_name [tool_version]

Example 1: ./trigger_tool_install.sh bamtools
The above command tells the trigger script to install the current version of Bamtools

Example 2: ./trigger_tool_install.sh bamtools v2.5.1
The above command tells the trigger script to install version v2.5.1

In some cases where we can't automate the process that gets the tool's current version, it's recommended to run the trigger with the version argument in addition to the tool name as shown in Example 2 above.

One such case is Trimmomatic -

Option 2. Running getToolVersion.sh/setToolVersion.sh and runGetPackage.sh scripts manually

  1. Get or Set The version of the tool to download
 Either by: 
     Running  ./getToolVersion.sh <tool_name> - to fetch the current version
     or 
     Running  ./setToolVersion.sh <tool_name> <version> - to specify the version

 Example:
   To get the current version of bamtools, run: ./getToolVersion.sh bamtools
   To specify that bamtools version v2.5.1 be installed,
      run : ./setToolVersion.sh bamtools v2.5.1

Running either one of the scripts will update 
the EXTERNAL_SOFTWARE_BASE/tool_name/current_release_NUMBER file.

The file current_release_NUMBER is used by runGetPackage.sh 
to install the specified version of the tool .

See the repos main configuration file Configuration 

  1. Install The Tool of interest
 Run ./runGetPackage.sh tool_name  - to install the version 
    of the tool set in the current_release file

Example:
  ./runGetPackage.sh bamtools

This will install bamtools-v2.5.1 under EXTERNAL_SOFTWARE_BASE/bamtools
then copies bin, includes, and lib files under SOFTWARE_BASE/bin,
SOFTWARE_BASE/includes, SOFTWARE_BASE/lib64, SOFTWARE_BASE/lib as needed.

Voila!

NOTE: If you provide the tool_version argument, make sure the format follows the pattern specified in REPOS_TAG_PATTERN variable in the tool's specific config file (*_package.cfg).

 For example in bedtools_package.cfg, 
the pattern Is  REPOS_TAG_PATTERN="^v[0-9]+\.[0-9]+\.[0-9]+$"

Example 1: ./trigger_tool_install.sh bedtools v2.5.1
is correct 

Example 2: ./trigger_tool_install.sh bedtools 2.5.1
is NOT correct