rpi-vsts-ci-led/pkg/cihook/cihook.go
2020-04-17 16:41:48 +08:00

12 lines
194 B
Go

package cihook
import "encoding/json"
func Parse(b []byte) (*PipelineEvent, error) {
p := &PipelineEvent{}
if err := json.Unmarshal(b, p); err != nil {
return nil, err
}
return p, nil
}