Class: UbuntuUpdate::Updater

Inherits:
Object
  • Object
show all
Defined in:
lib/ubuntu_update.rb

Constant Summary collapse

"echo '%{summary}'"
@@apt_get_command =
"sudo apt-get %{command}"

Instance Method Summary collapse

Constructor Details

#initialize(options_parser, command_executor) ⇒ Updater

Returns a new instance of Updater.



12
13
14
15
16
# File 'lib/ubuntu_update.rb', line 12

def initialize (options_parser, command_executor)
	@command_executor = command_executor
	@options_parser = options_parser
	@command_list = []
end

Instance Method Details

#execute_commandObject



18
19
20
# File 'lib/ubuntu_update.rb', line 18

def execute_command
	@command_executor.execute get_command
end