Module: Clipboard::Mac

Extended by:
Mac
Included in:
Mac
Defined in:
lib/clipboard/mac.rb

Instance Method Summary collapse

Instance Method Details

#clearObject



18
19
20
# File 'lib/clipboard/mac.rb', line 18

def clear
  copy ''
end

#copy(data) ⇒ Object



13
14
15
16
# File 'lib/clipboard/mac.rb', line 13

def copy(data)
  Utils.popen "pbcopy", data
  paste
end

#paste(_ = nil) ⇒ Object



9
10
11
# File 'lib/clipboard/mac.rb', line 9

def paste(_ = nil)
  `pbpaste`
end