Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: Environment Values

From: brian:hawley at: 12-Jul-2001 17:15

(I'm a little behind on my email...) Long ago, David Ness wrote:
>I've checked all the documentation I can think of, but still can't figure >out how to access the value of a Windows `Environmental Variable'. Can >someone point me in the right direction?
With /Command or /Pro you can access the C getenv function from the C library, or you can use the call function like a: "" call/output "echo %PATH%" a or for all variables a: "" call/output "set" a With all REBOLs you can pass them on the command line like rebol.exe --do "app-paths: {%PATH%}" blah.r and even preprocess them like this rebol.exe --do "app-paths: parse {%PATH%} {;}" blah.r which returns the PATH variable broken into its components. I used a trick like the latter one to implement REBOL batch files that could be anywhere in the PATH directories. A little late, but it might help. Brian Hawley