Class: Dri::Commands::Rm::Reports

Inherits:
Dri::Command show all
Defined in:
lib/dri/commands/rm/reports.rb

Instance Method Summary collapse

Methods inherited from Dri::Command

#add_color, #api_client, #bold, #command, #config, #cursor, #editor, #emoji, #handover_report_path, #logger, #ops_token, #pastel, #profile, #prompt, #spinner, #timezone, #token, #username, #verify_config_exists

Constructor Details

#initialize(options) ⇒ Reports

Returns a new instance of Reports.



10
11
12
# File 'lib/dri/commands/rm/reports.rb', line 10

def initialize(options)
  @options = options
end

Instance Method Details

#executeObject



14
15
16
# File 'lib/dri/commands/rm/reports.rb', line 14

def execute(*)
  FileUtils.rm_rf(handover_report_path) if prompt.yes?("Remove everything in #{handover_report_path}?")
end