@@ -30,11 +30,15 @@ type jsonWriter struct {
3030}
3131
3232type jsonMessage struct {
33- DryRun bool `json:"dry-run,omitempty"`
34- Tail bool `json:"tail,omitempty"`
35- ID string `json:"id,omitempty"`
36- Text string `json:"text,omitempty"`
37- Status string `json:"status,omitempty"`
33+ DryRun bool `json:"dry-run,omitempty"`
34+ Tail bool `json:"tail,omitempty"`
35+ ID string `json:"id,omitempty"`
36+ ParentID string `json:"parent_id,omitempty"`
37+ Text string `json:"text,omitempty"`
38+ Status string `json:"status,omitempty"`
39+ Current int64 `json:"current,omitempty"`
40+ Total int64 `json:"total,omitempty"`
41+ Percent int `json:"percent,omitempty"`
3842}
3943
4044func (p * jsonWriter ) Start (ctx context.Context ) error {
@@ -48,11 +52,15 @@ func (p *jsonWriter) Start(ctx context.Context) error {
4852
4953func (p * jsonWriter ) Event (e Event ) {
5054 var message = & jsonMessage {
51- DryRun : p .dryRun ,
52- Tail : false ,
53- ID : e .ID ,
54- Text : e .Text ,
55- Status : e .StatusText ,
55+ DryRun : p .dryRun ,
56+ Tail : false ,
57+ ID : e .ID ,
58+ Text : e .Text ,
59+ Status : e .StatusText ,
60+ ParentID : e .ParentID ,
61+ Current : e .Current ,
62+ Total : e .Total ,
63+ Percent : e .Percent ,
5664 }
5765 marshal , err := json .Marshal (message )
5866 if err == nil {
0 commit comments