Class: Yogi::ErrorOut

Inherits:
Object
  • Object
show all
Defined in:
lib/yogi.rb

Instance Method Summary collapse

Instance Method Details

#undoObject



347
348
349
350
351
352
353
354
355
356
357
358
359
# File 'lib/yogi.rb', line 347

def undo
  #undo changes originaly made.
  Dir.foreach('.git/.backupFiles') do |item|
    next if item == '.' or item == '..'
  FileUtils.cp_r ".git/.backupFiles/"+ item, "./"
  # puts item
    end
  #removes folder backupFiles
  FileUtils.rm_r '.git/.backupFiles'
  FileUtils.rm_r '.git/.ignoreme.json'
  FileUtils.rm_r '.git/.ignoremefile.txt'
  puts " Hope You had fun and try it again later."
end