class OtherTagGenerator

Public Instance Methods

next_tag(previous_tag_type, next_tag_type, tags_for_this_commit) click to toggle source
# File lib/build_promotion_tool/generator/other_tag_generator.rb, line 9
def next_tag(previous_tag_type, next_tag_type, tags_for_this_commit)
  tags_for_this_commit.select {|tag| /^#{previous_tag_type}-v\d+.\d+.\d*$/ =~ tag}
                      .map {|tag| tag.sub(previous_tag_type, next_tag_type)}
                      .map {|tag| tag.sub(/\n/, "")}
                      .first
end
tag_exists?(check_tag_type, tags_for_this_commit) click to toggle source
# File lib/build_promotion_tool/generator/other_tag_generator.rb, line 5
def tag_exists?(check_tag_type, tags_for_this_commit)
  tags_for_this_commit.any? {|tag| /^#{check_tag_type}-v\d+.\d+.\d*$/ =~ tag}
end