Skip to content

Commit

Permalink
Write progress for tabulate
Browse files Browse the repository at this point in the history
  • Loading branch information
zix99 committed Oct 27, 2019
1 parent f2114e1 commit dc85570
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions cmd/tabulate.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ func tabulateFunction(c *cli.Context) error {
}
writer.WriteRow(1+idx, rowVals...)
}
writer.InnerWriter().WriteForLine(1+len(rows), GetReadFileString())
})

fmt.Fprintf(os.Stderr, "Rows: %s; Cols: %s\n",
Expand Down
4 changes: 4 additions & 0 deletions pkg/multiterm/table.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@ func NewTable(maxCols, maxRows int) *TableWriter {
}
}

func (s *TableWriter) InnerWriter() *TermWriter {
return s.term
}

func (s *TableWriter) WriteRow(rowNum int, cols ...string) {
if rowNum >= s.maxRows {
return
Expand Down

0 comments on commit dc85570

Please sign in to comment.