Method: Specinfra::Command::Aix::Base::File.check_is_owned_by

Defined in:
lib/specinfra/command/aix/base/file.rb

.check_is_owned_by(file, owner) ⇒ Object


11
12
13
14
# File 'lib/specinfra/command/aix/base/file.rb', line 11

def check_is_owned_by(file, owner)
  regexp = "^#{owner}$"
  "ls -al #{escape(file)} | awk '{print $3}' | grep -- #{escape(regexp)}"
end