MCPcopy
hub / github.com/docker/compose / Start

Method Start

cmd/display/tty.go:158–175  ·  cmd/display/tty.go::ttyWriter.Start
(ctx context.Context, operation string)

Source from the content-addressed store, hash-verified

156}
157
158func (w *ttyWriter) Start(ctx context.Context, operation string) {
159 w.ticker = time.NewTicker(100 * time.Millisecond)
160 w.operation = operation
161 go func() {
162 for {
163 select {
164 case <-ctx.Done():
165 // interrupted
166 w.ticker.Stop()
167 return
168 case <-w.done:
169 return
170 case <-w.ticker.C:
171 w.print()
172 }
173 }
174 }()
175}
176
177func (w *ttyWriter) Done(operation string, success bool) {
178 w.print()

Callers

nothing calls this directly

Calls 3

printMethod · 0.95
DoneMethod · 0.65
StopMethod · 0.65

Tested by

no test coverage detected