comp.lang.ada
 help / color / mirror / Atom feed
From: evangeli <evangeli@cnam.fr>
Subject: retrieve command result
Date: Wed, 06 Nov 2002 17:43:46 +0100
Date: 2002-11-06T15:39:24+00:00	[thread overview]
Message-ID: <3DC946C2.3000505@cnam.fr> (raw)

hi all

is it possible to retrieve the result of a command in a variable.
i explain myself:

------------------------------------------------------------------
with GNAT.OS_Lib;
with Ada.Strings.Unbounded;
procedure Test is
	...
	my_string : Ada.Strings.Unbounded.unbounded_string;
	...
begin
	...
	GNAT.OS_Lib.Spawn("ls", ...);
	-- I WOULD LIKE TO GET IN my_string THE RESULT OF THE ls COMMAND
	...
end;
------------------------------------------------------------------

i am under linux with gnat 3.13p.

thanks for any help




             reply	other threads:[~2002-11-06 16:43 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-11-06 16:43 evangeli [this message]
2002-11-06 17:06 ` retrieve command result sk
2002-11-06 17:46 ` Stephen Leake
2002-11-07  9:43   ` Emmanuel Briot
2002-11-07 13:56     ` Stephen Leake
2002-11-07  1:48 ` Marc A. Criley
2002-11-07 15:46   ` evangeli
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox