Class: Recode::Handler::Prompt

Inherits:
Output show all
Defined in:
lib/recode/handler/prompt.rb

Instance Method Summary collapse

Methods inherited from Base

#rename_file, #save_file, #show_edit, #show_rename

Methods included from Diffing

#diff

Instance Method Details

#edit(file:, before:, after:) ⇒ Object



11
12
13
14
# File 'lib/recode/handler/prompt.rb', line 11

def edit(file:, before:, after:)
  super
  save_file file, after if apply?
end

#rename(source:, target:) ⇒ Object



6
7
8
9
# File 'lib/recode/handler/prompt.rb', line 6

def rename(source:, target:)
  super
  rename_file source, target if apply?
end