cupsffi 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: ac820f12c69456581085fbe72a228553dd9a65b8
4
+ data.tar.gz: 8de484ae6f6eb15b4c1acf6b2491dbc92a9b1d3e
5
+ SHA512:
6
+ metadata.gz: ebedc3464a41ae253f6a0ebed5ba1d2410e74671777fa8cf5ff33a7afa15b60349f41bc3e4f8138fbdc3491449d7b48c43d0bd783bf0233def6625f67badf662
7
+ data.tar.gz: 4b632a6e5f0f0f5a0c135a07c72ce78fcb53e775708f23157e760c6946c4e7283f59716d1d17fcd5d76367e20d2165f86a0c20c31598cdab4c977d3eae5858c5
@@ -168,14 +168,15 @@ class CupsPrinter
168
168
  # Examine each input option to make sure that both the key and value are
169
169
  # found in the ppd options.
170
170
  options.each do |key,value|
171
+ key_string = key.to_s
171
172
  # Accept common CUPS options
172
- next if ['copies'].include?(key)
173
+ next if ['copies'].include?(key_string)
173
174
 
174
- raise "Invalid option #{key} for printer #{@name}" if ppd_options[key].nil?
175
- choices = ppd_options[key][:choices].map{|c| c[:choice]}
175
+ raise "Invalid option #{key} for printer #{@name}" if ppd_options[key_string].nil?
176
+ choices = ppd_options[key_string][:choices].map{|c| c[:choice]}
176
177
  # Treat 'Custom.WIDTHxHEIGHT' as just 'Custom'
177
- base_value = (value =~ /^Custom\./ && %w{PageRegion PageSize}.include?(key)) ? 'Custom' : value
178
- raise "Invalid value #{value} for option #{key}" unless choices.include?(base_value)
178
+ base_value = (value =~ /^Custom\./ && %w{PageRegion PageSize}.include?(key_string)) ? 'Custom' : value
179
+ raise "Invalid value #{value} for option #{key_string}" unless choices.include?(base_value)
179
180
  end
180
181
  end
181
182
  end
@@ -1,3 +1,3 @@
1
1
  module Cupsffi
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,46 +1,41 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cupsffi
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
5
- prerelease:
4
+ version: 0.1.2
6
5
  platform: ruby
7
6
  authors:
8
7
  - Nathan Ehresman
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2013-04-08 00:00:00.000000000 Z
11
+ date: 2014-07-21 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: ffi
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
- - - ! '>='
17
+ - - '>='
20
18
  - !ruby/object:Gem::Version
21
19
  version: '0'
22
20
  type: :development
23
21
  prerelease: false
24
22
  version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
23
  requirements:
27
- - - ! '>='
24
+ - - '>='
28
25
  - !ruby/object:Gem::Version
29
26
  version: '0'
30
27
  - !ruby/object:Gem::Dependency
31
28
  name: ffi
32
29
  requirement: !ruby/object:Gem::Requirement
33
- none: false
34
30
  requirements:
35
- - - ! '>='
31
+ - - '>='
36
32
  - !ruby/object:Gem::Version
37
33
  version: '0'
38
34
  type: :runtime
39
35
  prerelease: false
40
36
  version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
37
  requirements:
43
- - - ! '>='
38
+ - - '>='
44
39
  - !ruby/object:Gem::Version
45
40
  version: '0'
46
41
  description: Simple wrapper around libcups to give CUPS printing capabilities to Ruby
@@ -65,26 +60,25 @@ files:
65
60
  - lib/cupsffi/version.rb
66
61
  homepage: https://github.com/nehresma/cupsffi
67
62
  licenses: []
63
+ metadata: {}
68
64
  post_install_message:
69
65
  rdoc_options: []
70
66
  require_paths:
71
67
  - lib
72
68
  required_ruby_version: !ruby/object:Gem::Requirement
73
- none: false
74
69
  requirements:
75
- - - ! '>='
70
+ - - '>='
76
71
  - !ruby/object:Gem::Version
77
72
  version: '0'
78
73
  required_rubygems_version: !ruby/object:Gem::Requirement
79
- none: false
80
74
  requirements:
81
- - - ! '>='
75
+ - - '>='
82
76
  - !ruby/object:Gem::Version
83
77
  version: '0'
84
78
  requirements: []
85
79
  rubyforge_project: cupsffi
86
- rubygems_version: 1.8.24
80
+ rubygems_version: 2.1.11
87
81
  signing_key:
88
- specification_version: 3
82
+ specification_version: 4
89
83
  summary: FFI wrapper around libcups
90
84
  test_files: []