Sha256: dcd3b40492752767347d5fec7bd0fb7f0b5fae07da3390ddc9608f485be143fb
Contents?: true
Size: 530 Bytes
Versions: 2
Compression:
Stored size: 530 Bytes
Contents
module Skype def self.exec(command) script = %Q{tell application "Skype" send command "#{Utils.escape command}" script name "#{self.config[:app_name]}" end tell} res = `unset LD_LIBRARY_PATH; unset DYLD_LIBRARY_PATH; /usr/bin/osascript -e '#{script}'`.strip @@filters.each do |filter, block| next unless res =~ filter res = block.call(res) break end res end module Utils def self.escape(str) str.gsub(/(["\\])/){ "\\#{$1}" }. gsub("'"){ "'\\''" } end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
skype-0.1.4 | lib/skype/platforms/mac.rb |
skype-0.1.3 | lib/skype/platforms/mac.rb |