How could I execute a system command such as cp somefile somedestination in Haskell?
Something like an os.Exec.
The Haskell 98 standard provides:
System.system :: String
-> IO GHC.IO.Exception.ExitCode
which executes a command.
The new System.Process library is more useful though, allowing for portable input/output redirection and so forth.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With