Sha256: 2ef0ced59d3fa3343b92051107d7a6800b14aef168838c4f7074b11699428db5
Contents?: true
Size: 922 Bytes
Versions: 20
Compression:
Stored size: 922 Bytes
Contents
# frozen_string_literal: true require 'lino' require_relative 'base' module RubyHelm module Commands class Upgrade < Base # rubocop:disable Metrics/MethodLength def configure_command(builder, opts) release = opts[:release] chart = opts[:chart] values = opts[:values] || {} should_install = opts[:install] paired_values = values.map do |key, value| "#{key}=#{value}" end builder.with_subcommand('upgrade') do |sub| unless values.empty? sub = sub.with_option( '--set', paired_values.join(','), separator: ' ' ) end sub = sub.with_flag('--install') if should_install sub end .with_argument(release) .with_argument(chart) end # rubocop:enable Metrics/MethodLength end end end
Version data entries
20 entries across 20 versions & 1 rubygems