Sha256: 71c44a50c54dd76448b89c8f224ba43573d4b6a1ca511e261d7ddab7a785a283
Contents?: true
Size: 411 Bytes
Versions: 7
Compression:
Stored size: 411 Bytes
Contents
module Shenzhen::PlistBuddy class << self def print(file, key) output = `/usr/libexec/PlistBuddy -c "Print :#{key}" "#{file}" 2> /dev/null` !output || output.empty? || /Does Not Exist/ === output ? nil : output.strip end def set(file, key, value) output = `/usr/libexec/PlistBuddy -c "Set #{key} #{value}" "#{file}" 2>&1` output == "" ? value : nil end end end
Version data entries
7 entries across 7 versions & 1 rubygems