Please enable JavaScript to view this site.

A-Shell Reference

Navigation: System Commands > SET

TITLE Definition String

Scroll Prev Top Next More

The SET TITLE command takes a string argument, optionally preceded by $TS, and which may contain any literal text that you want to appear as the title. If the $TS prefix is specified, the title will appear on the top status line; otherwise it will appear on the window title bar, providing you are running A-Shell/Windows, or you are using ZTERM as your terminal emulator to connect to some flavor of A-Shell/Unix. The following special variables may appear anywhere in the title string:

Variable

Displays

$NC

Name of last executed command (e.g. "SET", "LOG") or program.

$ND

Name of current logged in device (e.g. "DSK0")

$NJ

Your job name

$NP

Name of last program executed (same as $NC but excluding LITs)

$PA

Platform A-Shell was compiled for (e.g. "Linux", "Windows/32", etc).

$PN

Current p,pn (e.g. "[7,6]")

$VA

Version of A-Shell (e.g. "4.6(753)")

$VP

Version of current program or command (e.g. "1.0(123)")

 

If the title definition string contains any of the above variables, the title will be automatically updated when the value of that variable changes. For example, if the title is defined via:

SET TITLE Job $NJ running $NP version $VP in $ND:$PN

Then whenever the program name (excluding LITs) or the current logged in device or PPN changes, the title line will be updated, and would appear something like this:

Job TSKAAB running MYPROG version 1.0(123) in DSK0:[7,6]

If you do not specify the $TS prefix (for top status line) and you are not running on either A-Shell/Windows or using ZTERM as your emulator, then the title will just be ignored.

If you do specify the $TS prefix and you are running PolyShell, then the title on the top status line will be updated whenever you switch to that window. If you have job-specific information in the title string, then it is highly recommended that you use SET TITLE on each of the processes running under PolyShell; otherwise, when switching to a job or session with no title definition, the previously displayed title will remain, possibly causing confusion for the user.