list tags for docker image
Nobody has claimed this yet.
Assessment
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Newbie friendliness
- 35/100
Research direction
Read the repository's existing organization for programming tips first; the issue provides the complete listTags shell function and its bash/zsh placement. Done means documenting that snippet in the appropriate tip location and preserving its stated usage for Docker image tags.
Written by the indexing model from the issue text.
Description
Put the following script to ~/.bashrc or ~/.zshrc for bash, zsh respectively.
Then you can run listTags gogs/gogs, or listTags ubuntu to list docker image tags from the docker repository.
function listTags() {
local repo=${1}
local size=${2:-25}
local page=${3:-1}
[ -z "${repo}" ] && echo "Usage: listTags <repoName> [size] [pageIndex]" 1>&2 && return 1
if [[ $repo == *"/"* ]]; then
curl "https://hub.docker.com/v2/repositories/${repo}/tags/?page=${page}&page_size=${size}" 2>/dev/null | jq -r '.results[].name' | sort
else
curl "https://registry.hub.docker.com/api/content/v1/repositories/public/library/${repo}/tags?page=${page}&page_size=${size}" 2>/dev/null | jq -r '.results[].name' | sort
fi
}
- Dominant language
- Python
- Stars
- 5
- Forks
- 2
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from davideuler/programming-tips
-
Difficulty 2/5 1-3 hours Newbie friendliness 35/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 35/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 45/100
-
build milvus on Mac Open
Difficulty 3/5 1-2 days Newbie friendliness 35/100
-
Difficulty 3/5 1-2 days Newbie friendliness 28/100
All issues in davideuler/programming-tips
Similar issues
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
use-agent-os/agent-os#3314 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 75/100
BasedHardware/omi#15662 · 1 comment ·
-
documentation help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 62/100
AiursoftWeb/AnduinOS-2#19 ·