File tree Expand file tree Collapse file tree 2 files changed +7
-5
lines changed
Expand file tree Collapse file tree 2 files changed +7
-5
lines changed Original file line number Diff line number Diff line change 236236 :: String
237237 -> ExecOptions
238238 -> (ExecResult -> Effect Unit )
239- -> Effect Unit
239+ -> Effect ChildProcess
240240exec cmd opts callback =
241241 execImpl cmd (convertExecOptions opts) \err stdout' stderr' ->
242242 callback
@@ -249,7 +249,7 @@ foreign import execImpl
249249 :: String
250250 -> ActualExecOptions
251251 -> (Nullable Exception.Error -> Buffer -> Buffer -> Effect Unit )
252- -> Effect Unit
252+ -> Effect ChildProcess
253253
254254-- | Like `exec`, except instead of using a shell, it passes the arguments
255255-- | directly to the specified command.
@@ -258,7 +258,7 @@ execFile
258258 -> Array String
259259 -> ExecOptions
260260 -> (ExecResult -> Effect Unit )
261- -> Effect Unit
261+ -> Effect ChildProcess
262262execFile cmd args opts callback =
263263 execFileImpl cmd args (convertExecOptions opts) \err stdout' stderr' ->
264264 callback
@@ -272,7 +272,7 @@ foreign import execFileImpl
272272 -> Array String
273273 -> ActualExecOptions
274274 -> (Nullable Exception.Error -> Buffer -> Buffer -> Effect Unit )
275- -> Effect Unit
275+ -> Effect ChildProcess
276276
277277foreign import data ActualExecOptions :: Type
278278
Original file line number Diff line number Diff line change @@ -58,8 +58,10 @@ nonExistentExecutable done = do
5858
5959execLs :: Effect Unit
6060execLs = do
61- exec " ls >&2" defaultExecOptions \r ->
61+ -- returned ChildProcess is ignored here
62+ _ <- exec " ls >&2" defaultExecOptions \r ->
6263 log " redirected to stderr:" *> (Buffer .toString UTF8 r.stderr >>= log)
64+ pure unit
6365
6466execSyncEcho :: String -> Effect Unit
6567execSyncEcho str = do
You can’t perform that action at this time.
0 commit comments