Slide 16
Slide 16 text
31 func logToStdoutAndFile() error {¬
32 ▸ file, err := os.Create("test.log")¬
33 ▸ if err != nil {¬
34 ▸ ▸ return err¬
35 ▸ }¬
36 ▸ mw := io.MultiWriter(os.Stdout, file)¬
37 ▸ b := BullBear{mw}¬
38 ▸ return b.DoSomething()¬
39 }¬
ඪ४ग़ྗͱϑΝΠϧʹϩάΛग़ྗ͢Δ