Class: Scribbler::Executable

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

Instance Method Summary collapse

Instance Method Details

#cliObject



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

def cli
  CLIClient.new
end

#configObject



14
15
16
# File 'lib/scribbler/executable.rb', line 14

def config
  Scribbler.config
end

#install(options = {}) ⇒ Object

Runs installer, makes dirs and copy’s template files

options - Options from command in shell

:path - changes the path its installing config files too


8
9
10
11
12
# File 'lib/scribbler/executable.rb', line 8

def install(options={})
  install_path = options[:path] || config.default_install_path
  cli.run_command "mkdir -p #{install_path}"
  cli.mass_copy config.templates, install_path
end