Sha256: 515d695d2d51c1b4618e18c5f0aa99e51eb443fb9d2a58aff2c679c5354bbf71

Contents?: true

Size: 507 Bytes

Versions: 6

Compression:

Stored size: 507 Bytes

Contents

# frozen_string_literal: true

require 'json'
require 'chamber/commands/cloud/base'

module  Chamber
module  Commands
module  Cloud
class   Pull < Chamber::Commands::Cloud::Base
  attr_accessor :target_file

  def initialize(into:, **args)
    super

    self.target_file = into
  end

  def call
    if target_file
      shell.create_file(target_file,
                        ::JSON.pretty_generate(adapter.environment_variables))
    else
      adapter.environment_variables
    end
  end
end
end
end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
chamber-3.0.0rc2 lib/chamber/commands/cloud/pull.rb
chamber-2.14.3 lib/chamber/commands/cloud/pull.rb
chamber-3.0.0rc1 lib/chamber/commands/cloud/pull.rb
chamber-2.14.2 lib/chamber/commands/cloud/pull.rb
chamber-2.14.1 lib/chamber/commands/cloud/pull.rb
chamber-2.14.0 lib/chamber/commands/cloud/pull.rb