clipboard 1.1.1 → 1.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/CHANGELOG.md +4 -0
- data/README.md +3 -3
- data/clipboard.gemspec +0 -2
- data/lib/clipboard/linux.rb +4 -2
- data/lib/clipboard/utils.rb +11 -0
- data/lib/clipboard/version.rb +1 -1
- data/spec/clipboard_spec.rb +0 -1
- metadata +4 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 35bf4d71c38e0854369bfedf7b2db272f060ccd4eb6485be03d8935afbcaa200
|
4
|
+
data.tar.gz: 54a3a402a33fc33f20e2f12cc0c1969ff419ca3b6d81b331b7e1425959697bb4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ec0e087dc69c65e32445c2ea89f75f4b2e49578ca37db4cca7d53502004e3f51aee276c97b704d816fbb33cd93dec61940b495a4123b0fbc27b3cf8984dada42
|
7
|
+
data.tar.gz: 971fb5dd754b01b350718a2111c9219a7c0af7a8bb5b4d322ddd6b667b6a348b3bc9bdaf9b33722bdb446597590fd2cfe0572052b4178140102791486decac69
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
# Ruby Clipboard [![version](https://badge.fury.io/rb/clipboard.svg)](https://badge.fury.io/rb/clipboard) [<img src="https://travis-ci.org/janlelis/clipboard.
|
1
|
+
# Ruby Clipboard [![version](https://badge.fury.io/rb/clipboard.svg)](https://badge.fury.io/rb/clipboard) [<img src="https://travis-ci.org/janlelis/clipboard.svg" />](https://travis-ci.org/janlelis/clipboard)
|
2
2
|
|
3
3
|
Lets you access the clipboard on Linux, MacOS, Windows and Cygwin.
|
4
4
|
|
@@ -24,7 +24,7 @@ this is: `sudo apt-get install xclip`
|
|
24
24
|
### Multiple Clipboards
|
25
25
|
|
26
26
|
On Linux, you can choose from which clipboard you want to `paste` from by
|
27
|
-
passing it as an
|
27
|
+
passing it as an argument. The default is CLIPBOARD.
|
28
28
|
|
29
29
|
`copy` copies to all clipboards in `Clipboard::Linux::CLIPBOARDS`.
|
30
30
|
|
@@ -57,7 +57,7 @@ JRuby. On Linux, it always operates only on the CLIPBOARD clipboard.
|
|
57
57
|
### blip
|
58
58
|
|
59
59
|
**blip** is a handy commandline wrapper that lets you quickly copy file
|
60
|
-
content to your clipboard: [blip](
|
60
|
+
content to your clipboard: [blip](https://gist.github.com/janlelis/781835)!
|
61
61
|
|
62
62
|
### Copyright
|
63
63
|
|
data/clipboard.gemspec
CHANGED
data/lib/clipboard/linux.rb
CHANGED
@@ -1,5 +1,7 @@
|
|
1
1
|
require 'open3'
|
2
2
|
|
3
|
+
require_relative 'utils'
|
4
|
+
|
3
5
|
module Clipboard
|
4
6
|
module Linux
|
5
7
|
extend self
|
@@ -7,11 +9,11 @@ module Clipboard
|
|
7
9
|
CLIPBOARDS = %w[clipboard primary secondary].freeze
|
8
10
|
|
9
11
|
# check which backend to use
|
10
|
-
if
|
12
|
+
if Utils.executable_installed?('xclip')
|
11
13
|
WriteCommand = 'xclip'.freeze
|
12
14
|
ReadCommand = 'xclip -o'.freeze
|
13
15
|
Selection = proc{ |x| "-selection #{x}" }.freeze
|
14
|
-
elsif
|
16
|
+
elsif Utils.executable_installed?('xsel')
|
15
17
|
WriteCommand = 'xsel -i'.freeze
|
16
18
|
ReadCommand = 'xsel -o'.freeze
|
17
19
|
Selection = { 'clipboard' => '-b', 'primary' => '-p', 'secondary' => '-s' }.freeze
|
data/lib/clipboard/version.rb
CHANGED
data/spec/clipboard_spec.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: clipboard
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jan Lelis
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-05-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -56,6 +56,7 @@ files:
|
|
56
56
|
- lib/clipboard/java.rb
|
57
57
|
- lib/clipboard/linux.rb
|
58
58
|
- lib/clipboard/mac.rb
|
59
|
+
- lib/clipboard/utils.rb
|
59
60
|
- lib/clipboard/version.rb
|
60
61
|
- lib/clipboard/windows.rb
|
61
62
|
- spec/clipboard_spec.rb
|
@@ -83,7 +84,7 @@ requirements:
|
|
83
84
|
install xclip'
|
84
85
|
- On Windows, you will need the ffi gem.
|
85
86
|
rubyforge_project:
|
86
|
-
rubygems_version: 2.
|
87
|
+
rubygems_version: 2.7.6
|
87
88
|
signing_key:
|
88
89
|
specification_version: 4
|
89
90
|
summary: Access to the clipboard on Linux, MacOS, Windows, and Cygwin.
|