Class: DeleteFile
- Inherits:
-
EdrGenBase
- Object
- EdrGenBase
- DeleteFile
- Defined in:
- lib/edr_gen/delete_file.rb
Constant Summary collapse
- ACTIVITY =
"file_changes"
Constants included from YamlLogger
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(args) ⇒ DeleteFile
constructor
A new instance of DeleteFile.
Methods included from YamlLogger
Constructor Details
#initialize(args) ⇒ DeleteFile
Returns a new instance of DeleteFile.
6 7 8 9 10 11 12 13 |
# File 'lib/edr_gen/delete_file.rb', line 6 def initialize(args) @filepath = args[0] command = ["rm #{@filepath}"] validate_args super(command) end |
Instance Method Details
#call ⇒ Object
15 16 17 18 19 |
# File 'lib/edr_gen/delete_file.rb', line 15 def call puts " Attempting to delete file..." execute_process puts " File removed: #{@filepath}" end |