class

Mangrullo::ImageNameParser

Inherits Reference < Object

Utility class for parsing and manipulating Docker image names

Class methods

display_name(image_name : String, max_length : Int32 = Constants::Table::MAX_COLUMN_WIDTH) : String

Truncate image name for display

Source
format_with_tag(repository : String, tag : String) : String

Format image name with tag

Source
from_registry?(image_name : String, registry : String) : Bool

Check if image is from a specific registry

Source
get_registry(image_name : String) : String | Nil

Get registry host from image name if present

Source
get_repository(image_name : String) : String

Extract just the repository from an image name

Source
get_tag(image_name : String) : String

Extract just the tag from an image name

Source
has_custom_tag?(image_name : String) : Bool

Check if image has a custom tag (not 'latest')

Source
parse(image_name : String) : NamedTuple(repository: String, tag: String)

Parse image name into repository and tag parts

Source