Class: Shipitron::DockerImage
- Inherits:
-
Hashie::Dash
- Object
- Hashie::Dash
- Shipitron::DockerImage
- Defined in:
- lib/shipitron/docker_image.rb
Instance Method Summary collapse
Instance Method Details
#name_with_tag(tag_override = nil) ⇒ Object
8 9 10 11 12 13 14 15 16 17 |
# File 'lib/shipitron/docker_image.rb', line 8 def name_with_tag(tag_override = nil) tag_str = [tag_override, tag, ''].find {|str| !str.nil? } tag_str = tag_str.to_s if !tag_str.empty? && !tag_str.start_with?(':') tag_str = tag_str.dup.prepend(':') end "#{name}#{tag_str}" end |
#to_s ⇒ Object
19 20 21 |
# File 'lib/shipitron/docker_image.rb', line 19 def to_s name_with_tag end |