mirror of
https://github.com/containers/skopeo.git
synced 2025-09-21 18:09:08 +00:00
vendor.conf,vendor: vndr update for containers/image
Signed-off-by: Erik Hollensbe <github@hollensbe.org>
This commit is contained in:
9
vendor/github.com/docker/distribution/reference/normalize.go
generated
vendored
9
vendor/github.com/docker/distribution/reference/normalize.go
generated
vendored
@@ -123,11 +123,10 @@ func (c canonicalReference) Familiar() Named {
|
||||
}
|
||||
}
|
||||
|
||||
// EnsureTagged adds the default tag "latest" to a reference if it only has
|
||||
// TagNameOnly adds the default tag "latest" to a reference if it only has
|
||||
// a repo name.
|
||||
func EnsureTagged(ref Named) NamedTagged {
|
||||
namedTagged, ok := ref.(NamedTagged)
|
||||
if !ok {
|
||||
func TagNameOnly(ref Named) Named {
|
||||
if IsNameOnly(ref) {
|
||||
namedTagged, err := WithTag(ref, defaultTag)
|
||||
if err != nil {
|
||||
// Default tag must be valid, to create a NamedTagged
|
||||
@@ -137,7 +136,7 @@ func EnsureTagged(ref Named) NamedTagged {
|
||||
}
|
||||
return namedTagged
|
||||
}
|
||||
return namedTagged
|
||||
return ref
|
||||
}
|
||||
|
||||
// ParseAnyReference parses a reference string as a possible identifier,
|
||||
|
10
vendor/github.com/docker/distribution/reference/regexp.go
generated
vendored
10
vendor/github.com/docker/distribution/reference/regexp.go
generated
vendored
@@ -20,15 +20,15 @@ var (
|
||||
optional(repeated(separatorRegexp, alphaNumericRegexp)))
|
||||
|
||||
// domainComponentRegexp restricts the registry domain component of a
|
||||
// repository name to start with a component as defined by domainRegexp
|
||||
// repository name to start with a component as defined by DomainRegexp
|
||||
// and followed by an optional port.
|
||||
domainComponentRegexp = match(`(?:[a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])`)
|
||||
|
||||
// domainRegexp defines the structure of potential domain components
|
||||
// DomainRegexp defines the structure of potential domain components
|
||||
// that may be part of image names. This is purposely a subset of what is
|
||||
// allowed by DNS to ensure backwards compatibility with Docker image
|
||||
// names.
|
||||
domainRegexp = expression(
|
||||
DomainRegexp = expression(
|
||||
domainComponentRegexp,
|
||||
optional(repeated(literal(`.`), domainComponentRegexp)),
|
||||
optional(literal(`:`), match(`[0-9]+`)))
|
||||
@@ -51,14 +51,14 @@ var (
|
||||
// regexp has capturing groups for the domain and name part omitting
|
||||
// the separating forward slash from either.
|
||||
NameRegexp = expression(
|
||||
optional(domainRegexp, literal(`/`)),
|
||||
optional(DomainRegexp, literal(`/`)),
|
||||
nameComponentRegexp,
|
||||
optional(repeated(literal(`/`), nameComponentRegexp)))
|
||||
|
||||
// anchoredNameRegexp is used to parse a name value, capturing the
|
||||
// domain and trailing components.
|
||||
anchoredNameRegexp = anchored(
|
||||
optional(capture(domainRegexp), literal(`/`)),
|
||||
optional(capture(DomainRegexp), literal(`/`)),
|
||||
capture(nameComponentRegexp,
|
||||
optional(repeated(literal(`/`), nameComponentRegexp))))
|
||||
|
||||
|
Reference in New Issue
Block a user