oras-project / oras

OCI registry client - managing content like artifacts, images, packages
https://oras.land
Apache License 2.0
1.33k stars 161 forks source link

refactor: add printer for metadata output #1310

Closed qweeah closed 3 months ago

qweeah commented 3 months ago

What this PR does / why we need it: This PR adds a printer so user-specified cmd output in go scripting works as expected.

codecov[bot] commented 3 months ago

Codecov Report

Attention: Patch coverage is 91.07143% with 5 lines in your changes are missing coverage. Please review.

Project coverage is 82.10%. Comparing base (776f8df) to head (d99475b).

Files Patch % Lines
cmd/oras/internal/display/metadata/view/printer.go 72.22% 4 Missing and 1 partial :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1310 +/- ## ========================================== + Coverage 81.99% 82.10% +0.10% ========================================== Files 83 82 -1 Lines 4016 4040 +24 ========================================== + Hits 3293 3317 +24 Misses 500 500 Partials 223 223 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

qweeah commented 3 months ago

Discussed offline with @shizhMSFT, closing it and will refactor in more straightforward way.