Class: Backup::Runner
- Inherits:
-
Object
- Object
- Backup::Runner
- Defined in:
- lib/backup/runner.rb
Overview
Is invoked from the command line application and invokes the application’s optons as provided by the user on the command line
Instance Method Summary collapse
-
#initialize(argv) ⇒ Runner
constructor
Takes the command line options and parses them.
-
#run ⇒ Object
Operates on the options and invokes the respective functions.
Constructor Details
#initialize(argv) ⇒ Runner
Takes the command line options and parses them
14 15 16 |
# File 'lib/backup/runner.rb', line 14 def initialize(argv) = Options.new(argv) end |
Instance Method Details
#run ⇒ Object
Operates on the options and invokes the respective functions
19 20 21 22 23 24 25 |
# File 'lib/backup/runner.rb', line 19 def run if .cron create_cron elsif .database or .file create_backup end end |