cupsffi 0.1.7 → 0.1.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a00b751119118675b1800d921545223fd6ef3b27
4
- data.tar.gz: 6dc4313c292e275fecfc2c88f29354f1efc8c4df
3
+ metadata.gz: 89a425157bca4e04d084e35e0aacb44112cd6a9a
4
+ data.tar.gz: 06df524172c711b083cdba418867e94fca9a6cfb
5
5
  SHA512:
6
- metadata.gz: b8d58f814d61acab147f6c9f83c2c158a26df88b38a19ceffaf9fc0d99a53292e271c1895d639c654ba47d895efefa8f2ce0557fb2091dc3ec79364a13948123
7
- data.tar.gz: 60fc8f6a34d161e35dfa99bfd466324fce0f1ef38921c8fdf59bdaf9a90a28bf8e9d16210f9eccb4a8ff6f5d268a52d50ba69bd41ae0e4e6e1593055dd3e2555
6
+ metadata.gz: 3bdbfd3ee8a30757f0cc73cd96524046034b07b1314917119c234f499938d642671aaa5a1b8fc1ca6051a8f7d9bbc1749fc4db08697b8d08cbbe3d8b06943f4b
7
+ data.tar.gz: 82eb9544f5a22857d339020cfd50c15d3570e3adc6c5d9407c1c77461ae50e55a66cb254816ecdde9c717c9f53ae39b6c94b7a6df40b2235b560fbc0a4b84f82
@@ -93,6 +93,15 @@ class CupsPrinter
93
93
  release_connection(connection)
94
94
  hash
95
95
  end
96
+
97
+ def self.default_printer
98
+ connection = get_connection
99
+ walk_attributes(connection) do |dest|
100
+ return dest[:name].dup if dest[:is_default] == 1
101
+ end
102
+ release_connection(connection)
103
+ nil
104
+ end
96
105
 
97
106
  def attributes
98
107
  hash = {}
@@ -1,3 +1,3 @@
1
1
  module Cupsffi
2
- VERSION = "0.1.7"
2
+ VERSION = "0.1.8"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cupsffi
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.7
4
+ version: 0.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nathan Ehresman
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-06-02 00:00:00.000000000 Z
11
+ date: 2019-04-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: ffi
@@ -63,7 +63,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
63
63
  version: '0'
64
64
  requirements: []
65
65
  rubyforge_project: cupsffi
66
- rubygems_version: 2.5.1
66
+ rubygems_version: 2.6.14.1
67
67
  signing_key:
68
68
  specification_version: 4
69
69
  summary: FFI wrapper around libcups