equal
deleted
inserted
replaced
5 |
5 |
6 package cmd |
6 package cmd |
7 |
7 |
8 import ( |
8 import ( |
9 "io" |
9 "io" |
|
10 "os" |
10 |
11 |
11 "github.com/pkg/errors" |
12 "github.com/pkg/errors" |
12 "github.com/spf13/cobra" |
13 "github.com/spf13/cobra" |
13 |
14 |
14 "github.com/McKael/madon" |
15 "github.com/McKael/madon" |
82 |
83 |
83 // StreamListener(name string, hashTag string, events chan<- madon.StreamEvent, stopCh <-chan bool, doneCh chan<- bool) error |
84 // StreamListener(name string, hashTag string, events chan<- madon.StreamEvent, stopCh <-chan bool, doneCh chan<- bool) error |
84 err := gClient.StreamListener(streamName, tag, evChan, stop, done) |
85 err := gClient.StreamListener(streamName, tag, evChan, stop, done) |
85 if err != nil { |
86 if err != nil { |
86 errPrint("Error: %s", err.Error()) |
87 errPrint("Error: %s", err.Error()) |
87 return nil |
88 os.Exit(1) |
88 } |
89 } |
89 |
90 |
90 p, err := getPrinter() |
91 p, err := getPrinter() |
91 if err != nil { |
92 if err != nil { |
92 close(stop) |
93 close(stop) |