[Haskell-cafe] open a browser from the command line,
wait a few seconds, and shut it. (ie,
translate forking from bash to haskell)
Donald Bruce Stewart
dons at cse.unsw.edu.au
Thu Mar 8 16:37:31 EST 2007
> I have a bash script that opens a browser for a few seconds, and then
> closes it.
> Could someone point me up the equivelant(s) in haskell, h4sh, hsh,
> etc,0 and friends?
> I reckon this amounts to, what's the process for translating forking
> from bash to haskell.
> konqueror http://www.google.com &
> pid=$! # give the page some time to load
> sleep 5
> kill $pid
main = do
p <- run "xclock" 
signalProcess sigTERM p
r <- getProcessStatus True False p
run x args = forkProcess $ executeFile x True args Nothing
More information about the Haskell-Cafe