Class: Dru::Commands::DockerCompose

Inherits:
Dru::Command show all
Defined in:
lib/dru/commands/docker_compose.rb

Instance Attribute Summary collapse

Attributes inherited from Dru::Command

#options

Instance Method Summary collapse

Methods inherited from Dru::Command

#container_name_to_id, #cursor, #default_docker_compose, #docker_compose_paths, #editor, #environment, #environment_docker_compose, #exec_exist?, #generator, #pager, #platform, #project_configuration_path, #project_name, #prompt, #run_docker_compose_command, #screen, #which

Constructor Details

#initialize(options:, command:) ⇒ DockerCompose

Returns a new instance of DockerCompose.



10
11
12
13
# File 'lib/dru/commands/docker_compose.rb', line 10

def initialize(options:, command:)
  @options = options
  @command = command
end

Instance Attribute Details

#commandObject (readonly)

Returns the value of attribute command.



8
9
10
# File 'lib/dru/commands/docker_compose.rb', line 8

def command
  @command
end

Instance Method Details

#execute(input: $stdin, output: $stdout) ⇒ Object



15
16
17
# File 'lib/dru/commands/docker_compose.rb', line 15

def execute(input: $stdin, output: $stdout)
  run_docker_compose_command(*command, tty: true)
end