MCPcopy
hub / github.com/DarthSim/overmind / newMultiOutput

Function newMultiOutput

start/multi_output.go:34–49  ·  view source on GitHub ↗
(maxNameLength int, showTimestamps bool)

Source from the content-addressed store, hash-verified

32}
33
34func newMultiOutput(maxNameLength int, showTimestamps bool) *multiOutput {
35 o := multiOutput{
36 maxNameLength: utils.Max(maxNameLength, 6),
37 showTimestamps: showTimestamps,
38 ch: make(chan *bytes.Buffer, 128),
39 done: make(chan struct{}),
40 echoes: make(map[int64]io.Writer),
41 bufPool: sync.Pool{
42 New: func() interface{} { return new(bytes.Buffer) },
43 },
44 }
45
46 go o.listen()
47
48 return &o
49}
50
51func (o *multiOutput) Offset() int {
52 of := o.maxNameLength + len(outputSeparator)

Callers 1

newCommandFunction · 0.85

Calls 2

listenMethod · 0.95
MaxFunction · 0.92

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…