Class: Rebuild::Runner
- Inherits:
-
Object
- Object
- Rebuild::Runner
- Defined in:
- lib/rebuild/runner.rb
Instance Method Summary collapse
-
#initialize(repo_path, primary_scripts, scriptdir) ⇒ Runner
constructor
A new instance of Runner.
- #run ⇒ Object
Constructor Details
#initialize(repo_path, primary_scripts, scriptdir) ⇒ Runner
Returns a new instance of Runner.
5 6 7 8 9 |
# File 'lib/rebuild/runner.rb', line 5 def initialize(repo_path, primary_scripts, scriptdir) @repo_path = repo_path @primary_scripts = primary_scripts @script_directory = scriptdir end |
Instance Method Details
#run ⇒ Object
11 12 13 14 15 16 17 18 |
# File 'lib/rebuild/runner.rb', line 11 def run return no_script_found if script_paths.empty? script_paths.each do |path| puts "Running #{path}..." system('sh', path) end end |