Safe Haskell | None |
---|---|
Language | Haskell98 |
The System.Process.Typed module from typed-process
, but with
added conduit helpers.
- createSink :: MonadIO m => StreamSpec STInput (ConduitM ByteString o m ())
- createSource :: MonadIO m => StreamSpec STOutput (ConduitM i ByteString m ())
- withProcess :: MonadUnliftIO m => ProcessConfig stdin stdout stderr -> (Process stdin stdout stderr -> m a) -> m a
- withProcess_ :: MonadUnliftIO m => ProcessConfig stdin stdout stderr -> (Process stdin stdout stderr -> m a) -> m a
- withLoggedProcess_ :: MonadUnliftIO m => ProcessConfig stdin stdoutIgnored stderrIgnored -> (Process stdin (ConduitM () ByteString m ()) (ConduitM () ByteString m ()) -> m a) -> m a
- module System.Process.Typed
Conduit specific stuff
createSink :: MonadIO m => StreamSpec STInput (ConduitM ByteString o m ()) Source #
Provide input to a process by writing to a conduit.
Since: 1.2.1
createSource :: MonadIO m => StreamSpec STOutput (ConduitM i ByteString m ()) Source #
Read output from a process by read from a conduit.
Since: 1.2.1
Generalized functions
withProcess :: MonadUnliftIO m => ProcessConfig stdin stdout stderr -> (Process stdin stdout stderr -> m a) -> m a Source #
Same as withProcess
, but generalized to MonadUnliftIO
.
Since: 1.2.1
withProcess_ :: MonadUnliftIO m => ProcessConfig stdin stdout stderr -> (Process stdin stdout stderr -> m a) -> m a Source #
Same as withProcess_
, but generalized to MonadUnliftIO
.
Since: 1.2.1
withLoggedProcess_ :: MonadUnliftIO m => ProcessConfig stdin stdoutIgnored stderrIgnored -> (Process stdin (ConduitM () ByteString m ()) (ConduitM () ByteString m ()) -> m a) -> m a Source #
Run a process, throwing an exception on a failure exit code. This will store all output from stdout and stderr in memory for better error messages. Note that this will require unbounded memory usage, so caveat emptor.
This will ignore any previous settings for the stdout and stderr
streams, and instead force them to use createSource
.
Since: 1.2.3
Reexports
module System.Process.Typed