class KuberKit::Tools::FilePresenceChecker

Constants

FileNotFound

Public Instance Methods

check_dir!(dir_path) click to toggle source
# File lib/kuber_kit/tools/file_presence_checker.rb, line 19
def check_dir!(dir_path)
  unless dir_exists?(dir_path)
    raise FileNotFound, "Directory not found at path: #{dir_path}"
  end
  true
end
check_file!(file_path) click to toggle source
# File lib/kuber_kit/tools/file_presence_checker.rb, line 8
def check_file!(file_path)
  unless file_exists?(file_path)
    raise FileNotFound, "File not found at path: #{file_path}"
  end
  true
end
dir_exists?(dir_path) click to toggle source
# File lib/kuber_kit/tools/file_presence_checker.rb, line 26
def dir_exists?(dir_path)
  local_shell.dir_exists?(dir_path)
end
file_exists?(file_path) click to toggle source
# File lib/kuber_kit/tools/file_presence_checker.rb, line 15
def file_exists?(file_path)
  local_shell.file_exists?(file_path)
end