Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] No way to get list of all environment variables ?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2001-08-13 (14:27)
From: Markus Mottl <markus@m...>
Subject: Re: [Caml-list] No way to get list of all environment variables ?
On Mon, 13 Aug 2001, Berke Durak wrote:
> I'd like to get a list of all environment variables defined, to be
> able to pass them, suitably modified or at least augmented, to an
> execvpe'd process. Is there a way to do this ?

Sure: "Unix.environment ()" gives you the current process environment
as a string array, "Unix.execvpe" can be passed such an array (possibly
manipulated) as argument.

Markus Mottl

Markus Mottl                                   
Austrian Research Institute
for Artificial Intelligence        
Bug reports:  FAQ:
To unsubscribe, mail  Archives: