Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • $JOB_KEY$ - replaced with the Job ID
  • $JOB_SEQ$ - replaced with the Job Sequence Number
  • $JOB_NAME$ - replaced with the Job Name
  • $WSL_SCRIPT_<host script name in metadata>_CODE$ - see the Script Sourcing section for examplesTokens

Environment Variables

The following environment variables are set prior to running the command

...

Success and Failure Command Script Sourcing

The Script Sourcing feature of RED is also available to be used in the Success and Failure Commands, this allows referencing a Host Script from the RED metadata rather than a script the that exists on the operating system.

Example success command:

Code Block
languageshell
titleSuccess Command Script Sourcing
python "WSL_SCRIPT_my_python_success_script_CODE"

When this Success Command is executed at run-time RED will do the following:

  • Parse the command for RED Tokens
    • Write referenced metadata Host Scripts found in any Script Sourcing Tokens to the work directory  
    • Expand the RED Tokens in the command line, Script Sourcing Tokens are replaced with the full file path of the script
  • Set up the environment variables
  • Execute the expanded command