diff --git a/.gitignore b/.gitignore index f1c181e..a8213d2 100644 --- a/.gitignore +++ b/.gitignore @@ -7,6 +7,6 @@ # Test binary, build with `go test -c` *.test - +build/* # Output of the go coverage tool, specifically when used with LiteIDE *.out diff --git a/build/coap-client b/build/coap-client deleted file mode 100755 index 89b44e6..0000000 Binary files a/build/coap-client and /dev/null differ diff --git a/cmd/main.go b/cmd/main.go index 3f88e70..9ade790 100644 --- a/cmd/main.go +++ b/cmd/main.go @@ -3,13 +3,12 @@ package main import ( "errors" "flag" - "fmt" "log" "net/url" "os" "strings" - coap "github.com/dusanb94/coap-cli/coap" + coap "github.com/mainflux/coap-cli/coap" gocoap "github.com/dustin/go-coap" ) @@ -61,7 +60,7 @@ func checkType(c, n, a, r *bool) (gocoap.COAPType, error) { func printMsg(m *gocoap.Message) { if m != nil { - log.Printf("Type: %d\nCode: %s\nMessageID: %d\nToken: %s\nPayload: %s\n", + log.Printf("\nMESSAGE:\nType: %d\nCode: %s\nMessageID: %d\nToken: %s\nPayload: %s\n", m.Type, m.Code.String(), m.MessageID, m.Token, m.Payload) } } @@ -120,8 +119,6 @@ func main() { }) } - fmt.Println("sasa", []byte(*token)) - res, err := client.Send(t, code, uint16(*id), []byte(*token), []byte(*d), opts) if err != nil { log.Fatal("ERROR: ", err)