class EacRubyUtils::Envs::File

Attributes

env[R]
path[R]

Public Class Methods

new(env, path) click to toggle source
# File lib/eac_ruby_utils/envs/file.rb, line 8
def initialize(env, path)
  @env = env
  @path = path
end

Public Instance Methods

exist?() click to toggle source
# File lib/eac_ruby_utils/envs/file.rb, line 13
def exist?
  env.command('stat', path).execute[:exit_code].zero?
end
read() click to toggle source
# File lib/eac_ruby_utils/envs/file.rb, line 17
def read
  env.command('cat', path).execute!
end