diff options
author | Kaz Kylheku <kaz@kylheku.com> | 2014-02-18 23:46:51 -0800 |
---|---|---|
committer | Kaz Kylheku <kaz@kylheku.com> | 2014-02-18 23:46:51 -0800 |
commit | c720098b5f0eb58eef01fef4acbeccde00af2c75 (patch) | |
tree | 257c1010127a56d0641c84b4056c66e45fc70ec9 /txr.1 | |
parent | 6dbb219a3fb2152ca9991a073df7e45c553eadf4 (diff) | |
download | txr-c720098b5f0eb58eef01fef4acbeccde00af2c75.tar.gz txr-c720098b5f0eb58eef01fef4acbeccde00af2c75.tar.bz2 txr-c720098b5f0eb58eef01fef4acbeccde00af2c75.zip |
* eval.c (env_hash): new function.
(eval_init): Register env and env_hash functions. Register prog_args
and prog_args_full as *args* and *full-args*.
* lib.c (timegm_hack): Invalidate env_list, after mucking with
the environment via setenv and unsetenv.
* txr.c (prog_args_full, prog_args): New global variables.
(txr_main): Command-line processing converted to use TXR's
library. Populates prog_args_full and prog_args.
* txr.h (prog_args_full, prog_args): Declared.
* txr.1: Documented *args*, *full-args*, env and env-hash.
Diffstat (limited to 'txr.1')
-rw-r--r-- | txr.1 | 43 |
1 files changed, 43 insertions, 0 deletions
@@ -12131,6 +12131,49 @@ call compatibility with make-time. It may or may not have any effect on the output (since the UTC zone by definition doesn't have daylight savings time). +.SH ENVIRONMENT VARIABLES AND COMMAND LINE + +.SS Variables *args* and *args-full* + +The *args* variable holds a list of strings representing the remaining +arguments which follow any options processed by the txr executable, and the +script name. + +The *args-full* variable holds the original, complete list of arguments passed +from the operating system. + +Note: the *args* variable is nil during the processing of the command line, +so TXR Lisp invoked using the -p or -e option cannot use it. + +.SS Function env + +.TP +Syntax: + + (env) + +.TP +Description: + +The env function retrieves the list of environment variables. Each +variable is represented by a single entry in the list: a string which +contains an = (equal) character somewhere, separating the variable name +from its value. + +See also: the env-hash function. + +.SS Function env-hash + +Syntax: + + (env-hash) + +.TP +Description: + +The env-hash function constructs and returns an :equal-based hash. The hash is +populated with the environment variables, represented as key-value pairs. + .SH UNIX PROGRAMMING .SS Function errno |