From 619a39f7bb2275a086651fcf31619959f6d15c6b Mon Sep 17 00:00:00 2001 From: Qi Wang Date: Thu, 1 Aug 2019 15:35:26 -0400 Subject: fix search output limit close https://bugzilla.redhat.com/show_bug.cgi?id=1732280 From the bug Podman search returns 25 results even when limit option `--limit` is larger than 25(maxQueries). They want Podman to return `--limit` results. This PR fixes the number of output result. if --limit not set, return MIN(maxQueries, len(res)) if --limit is set, return MIN(option, len(res)) Signed-off-by: Qi Wang --- docs/podman-search.1.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'docs') diff --git a/docs/podman-search.1.md b/docs/podman-search.1.md index f0a696494..c68f94347 100644 --- a/docs/podman-search.1.md +++ b/docs/podman-search.1.md @@ -11,8 +11,8 @@ podman\-search - Search a registry for an image The user can specify which registry to search by prefixing the registry in the search term (example **registry.fedoraproject.org/fedora**), default is the registries in the **registries.search** table in the config file - **/etc/containers/registries.conf**. -The number of results can be limited using the **--limit** flag. If more than one registry -is being searched, the limit will be applied to each registry. The output can be filtered +The default number of results is 25. The number of results can be limited using the **--limit** flag. +If more than one registry is being searched, the limit will be applied to each registry. The output can be filtered using the **--filter** flag. To get all available images in a registry without a specific search term, the user can just enter the registry name with a trailing "/" (example **registry.fedoraproject.org/**). Note, searching without a search term will only work for registries that implement the v2 API. -- cgit v1.2.3-54-g00ecf