Sha256: 4d694fb5851930aa4fbd2b4ccf5f7afc2cd8b3c8e14e79d42f0b3058b7caab88

Contents?: true

Size: 711 Bytes

Versions: 74

Compression:

Stored size: 711 Bytes

Contents

# frozen_string_literal: true

require 'active_support/core_ext/hash/indifferent_access'
require 'active_support/core_ext/object/blank'
require 'shellwords'

module EacRubyUtils
  module Envs
    module BaseCommand
      module ExtraOptions
        # @return [ActiveSupport::HashWithIndifferentAccess]
        def extra_options
          @extra_options ||= {}.with_indifferent_access
        end

        def status_result(status_code, result)
          duplicate_by_extra_options(status_results: status_results.merge(status_code => result))
        end

        private

        def status_results
          extra_options[:status_results] ||= {}.with_indifferent_access
        end
      end
    end
  end
end

Version data entries

74 entries across 74 versions & 2 rubygems

Version Path
eac_ruby_utils-0.124.0 lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_tools-0.97.2 sub/eac_ruby_utils/lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_ruby_utils-0.123.0 lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_ruby_utils-0.121.0 lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_ruby_utils-0.120.0 lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_tools-0.76.1 sub/eac_ruby_utils/lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_tools-0.76.0 sub/eac_ruby_utils/lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_tools-0.75.2 sub/eac_ruby_utils/lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_ruby_utils-0.119.2 lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_tools-0.75.1 sub/eac_ruby_utils/lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_tools-0.75.0 sub/eac_ruby_utils/lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_ruby_utils-0.119.1 lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_tools-0.74.1 sub/eac_ruby_utils/lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_tools-0.74.0 sub/eac_ruby_utils/lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_tools-0.73.0 sub/eac_ruby_utils/lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_ruby_utils-0.119.0 lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_tools-0.72.0 sub/eac_ruby_utils/lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_ruby_utils-0.118.1 lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_ruby_utils-0.118.0 lib/eac_ruby_utils/envs/base_command/extra_options.rb
eac_tools-0.70.1 sub/eac_ruby_utils/lib/eac_ruby_utils/envs/base_command/extra_options.rb