MCPcopy Create free account
hub / github.com/linuxkit/linuxkit / main

Function main

pkg/kmsg/main.go:14–26  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

12)
13
14func main() {
15 parser, err := kmsgparser.NewParser()
16 if err != nil {
17 log.Fatalf("unable to create parser: %v", err)
18 }
19 defer parser.Close()
20
21 kmsg := parser.Parse()
22
23 for msg := range kmsg {
24 fmt.Fprintf(os.Stderr, "(%d) - %s: %s", msg.SequenceNumber, msg.Timestamp.Format(time.RFC3339Nano), msg.Message)
25 }
26}

Callers

nothing calls this directly

Calls 2

CloseMethod · 0.45
FormatMethod · 0.45

Tested by

no test coverage detected