Sha256: 9d5aa9c1203497fd9bc8550f5ccaaf526aba25325b3bc73b5ff36dcd4d1a6f05

Contents?: true

Size: 1.34 KB

Versions: 26

Compression:

Stored size: 1.34 KB

Contents

require 'fig/command/action'
require 'fig/command/action/role/has_no_sub_action'
require 'fig/package_definition_text_assembler'

module  Fig; end
class   Fig::Command; end
module  Fig::Command::Action; end

class Fig::Command::Action::DumpPackageDefinitionForCommandLine
  include Fig::Command::Action
  include Fig::Command::Action::Role::HasNoSubAction

  def options()
    return %w<--dump-package-definition-for-command-line>
  end

  def descriptor_requirement()
    return nil
  end

  def cares_about_asset_options?()
    return true
  end

  def modifies_repository?()
    return false
  end

  def load_base_package?()
    return true
  end

  def register_base_package?()
    return nil # don't care
  end

  def apply_config?()
    return nil # don't care
  end

  def configure(options)
    @environment_statements = options.environment_statements
    @asset_statements       = options.asset_statements

    return
  end

  def execute()
    text_assembler = Fig::PackageDefinitionTextAssembler.new :emit_as_input
    text_assembler.add_output @asset_statements
    text_assembler.add_output [
      Fig::Statement::Configuration.new(
        nil,
        nil,
        Fig::Package::DEFAULT_CONFIG,
        @environment_statements
      )
    ]

    unparsed, * = text_assembler.assemble_package_definition
    print unparsed

    return EXIT_SUCCESS
  end
end

Version data entries

26 entries across 26 versions & 1 rubygems

Version Path
fig-1.23.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.22.1.beta.1 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.22.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.21.1.beta.2 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.21.1.beta.1 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.21.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.20.1.beta.1 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.20.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.19.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.18.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.17.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.16.1.beta.1 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.16.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.15.1.beta.2 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.15.1.beta.1 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.15.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.14.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.13.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.12.0 lib/fig/command/action/dump_package_definition_for_command_line.rb
fig-1.11.0 lib/fig/command/action/dump_package_definition_for_command_line.rb