Class: DotfilesInstaller::Interactive
- Inherits:
-
Base
- Object
- Base
- DotfilesInstaller::Interactive
show all
- Defined in:
- lib/dotfiles_installer.rb
Overview
run the install or uninstall printing to $stdout and reading from $stdin
Instance Attribute Summary
Attributes inherited from Base
#homedir, #options, #sourcedir
Instance Method Summary
collapse
Methods inherited from Base
#initialize
Methods included from Utilities
#source_map, #source_paths
Instance Method Details
#install ⇒ Object
57
58
59
60
61
62
|
# File 'lib/dotfiles_installer.rb', line 57
def install
Runner.new($stdout).install(self.source_map) do |prompt, inputs|
$stdout.print "#{prompt} #{inputs} "
$stdin.gets.chomp
end
end
|
#uninstall ⇒ Object
64
65
66
67
68
69
|
# File 'lib/dotfiles_installer.rb', line 64
def uninstall
Runner.new($stdout).uninstall(self.source_map) do |prompt, inputs|
$stdout.print "#{prompt} #{inputs} "
$stdin.gets.chomp
end
end
|