Skip to content

Conversation

nothiaki
Copy link
Contributor

Does this PR introduce a user-facing change?

Yes, added the option to format the list showing the virtual size podman artifact ls --format '{{ .VirtualSize }}'
Closes #27085

Added virtual size option for artifact list --format

Signed-off-by: Celso Henrique Souza Silva <celsohenrique367@gmail.com>
@nothiaki
Copy link
Contributor Author

nothiaki commented Sep 24, 2025

I did not add tests because this test file already cover all commands with flag --format.

# Main test loop. Recursively runs 'podman [subcommand] help', looks for:
# > '[command]', which indicates, recurse; or
# > '--format', in which case we
# > check autocompletion, look for Go templates, in which case we
# > run the command with --format '{{"\n"}}' and make sure it passes

Copy link

[NON-BLOCKING] Packit jobs failed. @containers/packit-build please check. Everyone else, feel free to ignore.

@Honny1
Copy link
Member

Honny1 commented Sep 25, 2025

I did not add tests because this test file already cover all commands with flag --format.

# Main test loop. Recursively runs 'podman [subcommand] help', looks for:
# > '[command]', which indicates, recurse; or
# > '--format', in which case we
# > check autocompletion, look for Go templates, in which case we
# > run the command with --format '{{"\n"}}' and make sure it passes

Unfortunately, you will need to implement a part of the test yourself, such as creating an artifact. The function you found is a helper, which is called from this test:

@test "check Go template formatting" {

I am okay with extending the current test to include the creation of an artifact, etc.

@nothiaki nothiaki force-pushed the artifact-list-virtual-size branch from 8ba53d3 to 5ae0e0d Compare September 25, 2025 21:48
Signed-off-by: Celso Henrique Souza Silva <celsohenrique367@gmail.com>
Copy link
Member

@Honny1 Honny1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, LGTM. The failed CI test looks like a flake. Please retrigger it here: https://cirrus-ci.com/task/6296539838021632. As the PR author, you have permission to do so.

/LGTM

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Sep 29, 2025
Copy link
Member

@baude baude left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

openshift-ci bot commented Sep 29, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: baude, nothiaki

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Sep 29, 2025
@openshift-merge-bot openshift-merge-bot bot merged commit 6a6a8ab into containers:main Sep 29, 2025
81 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. release-note
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add podman artifact ls --format '{{ .VirtualSize }}'
4 participants