[Haskell] Capturing output from System.system

Bryan O'Sullivan bos at serpentine.com
Tue Jan 16 17:29:11 EST 2007


Mads Lindstrøm wrote:

> The function System.system (:: String -> IO ExitCode) makes the OS
> execute it first parameter as a command. It prints its output to
> standard output and standard error.
> 
> How do I easily capture this output?

There's Jens-U Petersen's rather old popenhs module, which you could 
dust off and use: http://www.haskell.org/~petersen/haskell/popenhs/

	<b



More information about the Haskell mailing list