Engine: integer job status, improved stream API
* Jobs return an integer status instead of a string * Status convention mimics unix process execution: 0=success, 1=generic error, 127="no such command" * Stdout and Stderr support multiple thread-safe data receivers and ring buffer filtering
This commit is contained in:
parent
bd292759f0
commit
bef8de9319
|
@ -24,7 +24,7 @@ type Job struct {
|
|||
Eng *Engine
|
||||
Name string
|
||||
Args []string
|
||||
env *Env
|
||||
env *Env
|
||||
Stdout *Output
|
||||
Stderr *Output
|
||||
Stdin *Input
|
||||
|
|
|
@ -185,9 +185,8 @@ func (o *Output) AddEnv() (dst *Env, err error) {
|
|||
if err != nil {
|
||||
return
|
||||
}
|
||||
*dst= *env
|
||||
*dst = *env
|
||||
}
|
||||
}()
|
||||
return dst, nil
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue