Global Variables

Global variables always return the same value throughout the Workspace.

Environment Variable Description
$$PRJNAME Returns the name of the current .rtp Project file
$$PRJDIR Returns the directory name of the current .rtp Project file
$$PRJPATH Returns the absolute path of the current .rtp Project file
$$VCSDIR Returns the local repository for files retrieved from Rational ClearCase, as specified in the ClearCase Preferences dialog box
$$CPPINCLUDES Returns the directory of C and C++ include files, as specified in the Directories Preferences dialog box
$$PERL

Returns the full command-line to run the PERL interpreter included with the product.

$$PERL allows to execute any perl script when its absolute or relative (from project) path is specified.

If no path is specified, then the script will be searched in the following locations:

1. Current project path ($$PRJPATH)

2. $TESTRTDIR/lib/scripts

Examples:

To remove foo.txt and bar.obj from project directory by using the script perlrm.pl:

$$PERL perlrm foo.txt bar.obj

To copy file to target directory by using the script perlcp.pl:

$$PERL perlcp file.txt

$$CLIPBOARD Returns the text content of the clipboard
$$VCSITEMS Returns a list of files managed by the CMS tool. If a single source file is selected, $$VCSITEMS returns the absolute path of the file. If a group or test node is selected, $$VCSITEMS returns a list of all files that must be registered in the configuration database (test script and reports).
$$OUTDIR Returns the INTDIR perl value, as specified in the temporary directory, where the temporary files are created during the Build process are located.
$$REPORTDIR Returns the OUTDIR perl value, as specified in the report directory, where test and analysis results are created.