ghcup-0.1.18.0: ghc toolchain installer
Copyright(c) Julian Ospald 2020
LicenseLGPL-3.0
Maintainerhasufell@hasufell.de
Stabilityexperimental
Portabilityportable
Safe HaskellNone
LanguageHaskell2010

GHCup.Prelude.Process

Description

 
Synopsis

Documentation

executeOut Source #

Arguments

:: MonadIO m 
=> FilePath

command as filename, e.g. ls

-> [String]

arguments to the command

-> Maybe FilePath

chdir to this path

-> m CapturedProcess 

Execute the given command and collect the stdout, stderr and the exit code. The command is run in a subprocess.

execLogged Source #

Arguments

:: (MonadReader env m, HasSettings env, HasLog env, HasDirs env, MonadIO m, MonadThrow m) 
=> FilePath

thing to execute

-> [String]

args for the thing

-> Maybe FilePath

optionally chdir into this

-> FilePath

log filename (opened in append mode)

-> Maybe [(String, String)]

optional environment

-> m (Either ProcessError ()) 

exec Source #

Arguments

:: MonadIO m 
=> String

thing to execute

-> [String]

args for the thing

-> Maybe FilePath

optionally chdir into this

-> Maybe [(String, String)]

optional environment

-> m (Either ProcessError ()) 

Thin wrapper around executeFile.