aboutsummaryrefslogtreecommitdiff
path: root/pkg/language/doc/set.hlp
diff options
context:
space:
mode:
authorJoe Hunkeler <jhunkeler@gmail.com>2015-08-11 16:51:37 -0400
committerJoe Hunkeler <jhunkeler@gmail.com>2015-08-11 16:51:37 -0400
commit40e5a5811c6ffce9b0974e93cdd927cbcf60c157 (patch)
tree4464880c571602d54f6ae114729bf62a89518057 /pkg/language/doc/set.hlp
downloadiraf-osx-40e5a5811c6ffce9b0974e93cdd927cbcf60c157.tar.gz
Repatch (from linux) of OSX IRAF
Diffstat (limited to 'pkg/language/doc/set.hlp')
-rw-r--r--pkg/language/doc/set.hlp82
1 files changed, 82 insertions, 0 deletions
diff --git a/pkg/language/doc/set.hlp b/pkg/language/doc/set.hlp
new file mode 100644
index 00000000..1b552eb4
--- /dev/null
+++ b/pkg/language/doc/set.hlp
@@ -0,0 +1,82 @@
+.help set,reset Apr87 language
+.ih
+NAME
+.nf
+ set -- set the value of an IRAF environment variable
+reset -- reset (overwrite) the value of an IRAF environment variable
+.fi
+.ih
+USAGE
+.nf
+set [varname = valuestring]
+reset [varname = valuestring]
+.fi
+.ih
+PARAMETERS
+.ls varname
+The environment variable to be defined or set.
+.le
+.ls valuestring
+The new string value of the environment variable.
+.le
+.ih
+DESCRIPTION
+The CL maintains a list of environment variables, each of which consists
+of a keyword = value pair. The \fIset\fR and \fIreset\fR operators are used
+to define new environment variables, or to set new values for old environment
+variables. The two operators are equivalent with the exception that if the
+named environment variable is already defined, \fIset\fR will push a new,
+temporary value for the variable, whereas \fIreset\fR will overwrite the most
+recent definition of the variable. Environment variables may be examined
+using the \fIshow\fR task or the \fIenvget\fR intrinsic function.
+
+A particular use for the environment variables is in the definition
+of IRAF logical names for directories. If an environment variable is set to
+a string corresponding to a system-dependent directory name,
+then the environment variable may then be used within the CL to
+refer to that directory.
+
+For example,
+
+.nf
+ set testdir = "/usr/iraf/testdir" # Unix
+ set testdir = "dua2:[iraf.testdir]" # VMS
+ task tst1 = testdir$tst1.cl
+.fi
+
+New IRAF logicals may be defined in terms or existing IRAF logical names,
+i.e., logical names are recursively expanded.
+
+.nf
+ set subdir1 = testdir$subdir1/
+ task tst2 = subdir1$tst2.e
+.fi
+
+If the \fIset\fR command is entered without any arguments the current
+environment list is printed in the reverse of the order in which the
+definitions were made. If a variable has been redefined both the
+final and original definition are shown. The \fIshow\fR command can be
+used to show only the current value.
+.ih
+EXAMPLES
+1. Define the data directory "dd" on a remote node, and call \fIimplot\fR
+to make plots of an image which resides in the remote directory.
+
+.nf
+ cl> set dd = lyra!/u2/me/data
+ cl> implot dd$picture
+.fi
+
+2. Temporarily change the value of the variable \fIprinter\fR. The new
+value is discarded when the \fIbye\fR is entered.
+
+.nf
+ cl> cl
+ cl> set printer = qms
+ ...
+ cl> bye
+.fi
+.ih
+SEE ALSO
+show, envget
+.endhelp