separate print logic from write logic

This commit is contained in:
natercio committed 2025-12-04 13:04:30 +00:00
1 parent f651ce8597
commit b12c519fdb
7 files changed
+462 -233

No files matched your search

+4 -2
View File
@@ -55,7 +55,7 @@ func run(ctx context.Context, platform string) error {
reader := factory()
writer := internal.NewTableWriter(os.Stdout)
writer := internal.NewAggregatorWriter()
eg.Go(func() error {
return internal.BuildReport(ctx, reader, writer)
@@ -66,7 +66,9 @@ func run(ctx context.Context, platform string) error {
return err
}
writer.Render()
printer := NewPrettyPrinter(os.Stdout)
printer.Render(writer)
return nil
}