[REBOL] system/options/args can be accessed in user.r
From: anton::lexicon::net at: 4-Sep-2002 15:39
This took me a while to figure out,
so this is a way to pass information from
the command-line to your user.r.
---- user.r ----
...
use [args][
if args: system/options/args [
do load first args
]
]
if value? 'print-hello? [
print "hello"
]
--------
Now, in the console, type:
rebol.exe -- "print-hello?: true"
and when the rebol console pops open it should
print the message.
This does not work with system/script/args.
system/script/args appears to be only available
after user.r has been run - ie. too late.
The above was tested on win2k and
REBOL/View 1.2.1.3.1 21-Jun-2001
REBOL/View 1.2.8.3.1 3-Aug-2002 (the latest beta)
Anton.