summaryrefslogtreecommitdiff
path: root/src/Script
diff options
context:
space:
mode:
authorRoman Smrž <roman.smrz@seznam.cz>2025-08-30 22:09:14 +0200
committerRoman Smrž <roman.smrz@seznam.cz>2025-09-01 20:44:22 +0200
commit27bf4a78b7203ed77790c92134213c3398214daa (patch)
tree5e17a92e4d4704ede7823595f42fb45ef686afbf /src/Script
parentfc40dfc41e8b3fbbe830846499ccce122930b235 (diff)
Add "ignore" commandHEADmaster
Changelog: Added `ignore` builtin command
Diffstat (limited to 'src/Script')
-rw-r--r--src/Script/Shell.hs8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/Script/Shell.hs b/src/Script/Shell.hs
index 1c052b0..23c3891 100644
--- a/src/Script/Shell.hs
+++ b/src/Script/Shell.hs
@@ -123,6 +123,7 @@ executeScript sei@ShellExecInfo {..} pstdin pstdout pstderr (ShellScript stateme
spawnShell :: Node -> ProcName -> ShellScript -> TestRun Process
spawnShell procNode procName script = do
procOutput <- liftIO $ newTVarIO []
+ procIgnore <- liftIO $ newTVarIO ( 0, [] )
seiStatusVar <- liftIO $ newEmptyMVar
( pstdin, procStdin ) <- createPipeCloexec
( hout, pstdout ) <- createPipeCloexec
@@ -139,12 +140,7 @@ spawnShell procNode procName script = do
let procKillWith = Nothing
let process = Process {..}
- void $ forkTest $ lineReadingLoop process hout $ \line -> do
- outProc OutputChildStdout process line
- liftIO $ atomically $ modifyTVar procOutput (++ [ line ])
- void $ forkTest $ lineReadingLoop process herr $ \line -> do
- outProc OutputChildStderr process line
-
+ startProcessIOLoops process hout herr
return process
withShellProcess :: Node -> ProcName -> ShellScript -> (Process -> TestRun a) -> TestRun a