cupertino 0.7.1 → 0.8.0

Sign up to get free protection for your applications and to get access to all the features.
metadata CHANGED
@@ -1,52 +1,18 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cupertino
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.1
5
- prerelease:
4
+ version: 0.8.0
6
5
  platform: ruby
7
6
  authors:
8
7
  - Mattt Thompson
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2012-12-04 00:00:00.000000000 Z
11
+ date: 2013-05-02 00:00:00.000000000 Z
13
12
  dependencies:
14
- - !ruby/object:Gem::Dependency
15
- name: rspec
16
- requirement: !ruby/object:Gem::Requirement
17
- none: false
18
- requirements:
19
- - - ~>
20
- - !ruby/object:Gem::Version
21
- version: 0.6.1
22
- type: :development
23
- prerelease: false
24
- version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
- requirements:
27
- - - ~>
28
- - !ruby/object:Gem::Version
29
- version: 0.6.1
30
- - !ruby/object:Gem::Dependency
31
- name: rake
32
- requirement: !ruby/object:Gem::Requirement
33
- none: false
34
- requirements:
35
- - - ~>
36
- - !ruby/object:Gem::Version
37
- version: 0.9.2
38
- type: :development
39
- prerelease: false
40
- version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
- requirements:
43
- - - ~>
44
- - !ruby/object:Gem::Version
45
- version: 0.9.2
46
13
  - !ruby/object:Gem::Dependency
47
14
  name: commander
48
15
  requirement: !ruby/object:Gem::Requirement
49
- none: false
50
16
  requirements:
51
17
  - - ~>
52
18
  - !ruby/object:Gem::Version
@@ -54,7 +20,6 @@ dependencies:
54
20
  type: :runtime
55
21
  prerelease: false
56
22
  version_requirements: !ruby/object:Gem::Requirement
57
- none: false
58
23
  requirements:
59
24
  - - ~>
60
25
  - !ruby/object:Gem::Version
@@ -62,7 +27,6 @@ dependencies:
62
27
  - !ruby/object:Gem::Dependency
63
28
  name: terminal-table
64
29
  requirement: !ruby/object:Gem::Requirement
65
- none: false
66
30
  requirements:
67
31
  - - ~>
68
32
  - !ruby/object:Gem::Version
@@ -70,7 +34,6 @@ dependencies:
70
34
  type: :runtime
71
35
  prerelease: false
72
36
  version_requirements: !ruby/object:Gem::Requirement
73
- none: false
74
37
  requirements:
75
38
  - - ~>
76
39
  - !ruby/object:Gem::Version
@@ -78,7 +41,6 @@ dependencies:
78
41
  - !ruby/object:Gem::Dependency
79
42
  name: term-ansicolor
80
43
  requirement: !ruby/object:Gem::Requirement
81
- none: false
82
44
  requirements:
83
45
  - - ~>
84
46
  - !ruby/object:Gem::Version
@@ -86,7 +48,6 @@ dependencies:
86
48
  type: :runtime
87
49
  prerelease: false
88
50
  version_requirements: !ruby/object:Gem::Requirement
89
- none: false
90
51
  requirements:
91
52
  - - ~>
92
53
  - !ruby/object:Gem::Version
@@ -94,7 +55,6 @@ dependencies:
94
55
  - !ruby/object:Gem::Dependency
95
56
  name: mechanize
96
57
  requirement: !ruby/object:Gem::Requirement
97
- none: false
98
58
  requirements:
99
59
  - - ~>
100
60
  - !ruby/object:Gem::Version
@@ -102,7 +62,6 @@ dependencies:
102
62
  type: :runtime
103
63
  prerelease: false
104
64
  version_requirements: !ruby/object:Gem::Requirement
105
- none: false
106
65
  requirements:
107
66
  - - ~>
108
67
  - !ruby/object:Gem::Version
@@ -110,7 +69,6 @@ dependencies:
110
69
  - !ruby/object:Gem::Dependency
111
70
  name: security
112
71
  requirement: !ruby/object:Gem::Requirement
113
- none: false
114
72
  requirements:
115
73
  - - ~>
116
74
  - !ruby/object:Gem::Version
@@ -118,7 +76,6 @@ dependencies:
118
76
  type: :runtime
119
77
  prerelease: false
120
78
  version_requirements: !ruby/object:Gem::Requirement
121
- none: false
122
79
  requirements:
123
80
  - - ~>
124
81
  - !ruby/object:Gem::Version
@@ -126,7 +83,6 @@ dependencies:
126
83
  - !ruby/object:Gem::Dependency
127
84
  name: shenzhen
128
85
  requirement: !ruby/object:Gem::Requirement
129
- none: false
130
86
  requirements:
131
87
  - - ! '>='
132
88
  - !ruby/object:Gem::Version
@@ -134,7 +90,6 @@ dependencies:
134
90
  type: :runtime
135
91
  prerelease: false
136
92
  version_requirements: !ruby/object:Gem::Requirement
137
- none: false
138
93
  requirements:
139
94
  - - ! '>='
140
95
  - !ruby/object:Gem::Version
@@ -142,7 +97,6 @@ dependencies:
142
97
  - !ruby/object:Gem::Dependency
143
98
  name: certified
144
99
  requirement: !ruby/object:Gem::Requirement
145
- none: false
146
100
  requirements:
147
101
  - - ! '>='
148
102
  - !ruby/object:Gem::Version
@@ -150,11 +104,38 @@ dependencies:
150
104
  type: :runtime
151
105
  prerelease: false
152
106
  version_requirements: !ruby/object:Gem::Requirement
153
- none: false
154
107
  requirements:
155
108
  - - ! '>='
156
109
  - !ruby/object:Gem::Version
157
110
  version: 0.1.0
111
+ - !ruby/object:Gem::Dependency
112
+ name: rspec
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - ! '>='
116
+ - !ruby/object:Gem::Version
117
+ version: '0'
118
+ type: :development
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - ! '>='
123
+ - !ruby/object:Gem::Version
124
+ version: '0'
125
+ - !ruby/object:Gem::Dependency
126
+ name: rake
127
+ requirement: !ruby/object:Gem::Requirement
128
+ requirements:
129
+ - - ! '>='
130
+ - !ruby/object:Gem::Version
131
+ version: '0'
132
+ type: :development
133
+ prerelease: false
134
+ version_requirements: !ruby/object:Gem::Requirement
135
+ requirements:
136
+ - - ! '>='
137
+ - !ruby/object:Gem::Version
138
+ version: '0'
158
139
  description: A command-line interface for the iOS Provisioning Portal
159
140
  email: m@mattt.me
160
141
  executables:
@@ -162,7 +143,6 @@ executables:
162
143
  extensions: []
163
144
  extra_rdoc_files: []
164
145
  files:
165
- - ./cupertino-0.7.0.gem
166
146
  - ./cupertino.gemspec
167
147
  - ./Gemfile
168
148
  - ./Gemfile.lock
@@ -172,7 +152,6 @@ files:
172
152
  - ./lib/cupertino/provisioning_portal/commands/devices.rb
173
153
  - ./lib/cupertino/provisioning_portal/commands/login.rb
174
154
  - ./lib/cupertino/provisioning_portal/commands/logout.rb
175
- - ./lib/cupertino/provisioning_portal/commands/pass_type_ids.rb
176
155
  - ./lib/cupertino/provisioning_portal/commands/profiles.rb
177
156
  - ./lib/cupertino/provisioning_portal/commands.rb
178
157
  - ./lib/cupertino/provisioning_portal/helpers.rb
@@ -183,33 +162,27 @@ files:
183
162
  - ./README.md
184
163
  - bin/ios
185
164
  homepage: http://mattt.me
186
- licenses: []
165
+ licenses:
166
+ - MIT
167
+ metadata: {}
187
168
  post_install_message:
188
169
  rdoc_options: []
189
170
  require_paths:
190
171
  - lib
191
172
  required_ruby_version: !ruby/object:Gem::Requirement
192
- none: false
193
173
  requirements:
194
174
  - - ! '>='
195
175
  - !ruby/object:Gem::Version
196
176
  version: '0'
197
- segments:
198
- - 0
199
- hash: 4171081425387838220
200
177
  required_rubygems_version: !ruby/object:Gem::Requirement
201
- none: false
202
178
  requirements:
203
179
  - - ! '>='
204
180
  - !ruby/object:Gem::Version
205
181
  version: '0'
206
- segments:
207
- - 0
208
- hash: 4171081425387838220
209
182
  requirements: []
210
183
  rubyforge_project:
211
- rubygems_version: 1.8.24
184
+ rubygems_version: 2.0.3
212
185
  signing_key:
213
- specification_version: 3
186
+ specification_version: 4
214
187
  summary: Cupertino
215
188
  test_files: []
data/cupertino-0.7.0.gem DELETED
Binary file
@@ -1,139 +0,0 @@
1
- command :'pass_type_ids:list' do |c|
2
- c.syntax = 'ios pass_type_ids:list'
3
- c.summary = 'Lists the Pass Type IDs'
4
- c.description = ''
5
-
6
- c.action do |args, options|
7
- pass_type_ids = try{agent.list_pass_type_ids}
8
-
9
- say_warning "No pass type IDs found." and abort if pass_type_ids.empty?
10
-
11
- table = Terminal::Table.new do |t|
12
- t << ["Card ID", "Identifier", "Description", "Pass Certificates"]
13
- t.add_separator
14
- pass_type_ids.each do |pass_type_id|
15
- t << [pass_type_id.card_id, pass_type_id.id, pass_type_id.description, pass_type_id.pass_certificates]
16
- end
17
- end
18
-
19
- puts table
20
- end
21
- end
22
-
23
- alias_command :pass_type_ids, :'pass_type_ids:list'
24
-
25
- command :'pass_type_ids:add' do |c|
26
- c.syntax = 'ios pass_type_ids:add PASS_TYPE_ID --description STRING'
27
- c.summary = 'Adds the Pass Type to the Provisioning Portal'
28
- c.description = ''
29
- c.option '-d', '--description DESCRIPTION', 'Description'
30
-
31
- c.action do |args, options|
32
- pass_type_id = args.first
33
- pass_type_id ||= ask "Pass Type ID:"
34
- say_error "Pass Type ID must begin with the string 'pass.' and use reverse-domain name style. Example: pass.domainname.passname" and abort unless PASS_TYPE_ID_REGEXP === pass_type_id
35
-
36
- description = options.description
37
- description ||= ask "Description (alphanumeric characters and spaces only):"
38
- say_error "Invalid description. Only alphanumeric characters and spaces are allowed." and abort unless /^[\w ]*$/ === description
39
-
40
- agent.add_pass_type_id(pass_type_id, description)
41
-
42
- say_ok "Added #{pass_type_id}: #{description}"
43
- end
44
- end
45
-
46
- command :'pass_type_ids:certificates:list' do |c|
47
- c.syntax = 'ios pass_type_ids:certificates:list PASS_TYPE_ID'
48
- c.summary = 'Lists the Pass Certificates for a specific Pass Type ID'
49
- c.description = ''
50
-
51
- c.action do |args, options|
52
- pass_type_id = args.first || determine_pass_type_id!
53
-
54
- pass_certificates = try{agent.list_pass_certificates(pass_type_id)}
55
- say_warning "No pass certificates found for Pass Type ID (#{pass_type_id})." and abort if pass_certificates.empty?
56
-
57
- table = Terminal::Table.new do |t|
58
- t << ["Name", "Status", "Expiration Date", "Certificate ID"]
59
-
60
- t.add_separator
61
-
62
- pass_certificates.each do |pass_certificate|
63
- t << [pass_certificate.name, pass_certificate.status, pass_certificate.expiration_date, pass_certificate.certificate_id]
64
- end
65
- end
66
-
67
- puts table
68
- end
69
- end
70
-
71
- alias_command :'pass_type_ids:certificates', :'pass_type_ids:certificates:list'
72
-
73
- command :'pass_type_ids:certificates:add' do |c|
74
- c.syntax = 'ios pass_type_ids:certificates:add PASS_TYPE_ID --csr STRING'
75
- c.summary = 'Adds the pass certificate for pass type ID to the Provisioning Portal'
76
- c.description = ''
77
- c.option '-r', '--csr CERTIFICATE_SIGNING_REQUEST', 'Path to Certificate Signing Request (CSR)'
78
-
79
- c.action do |args, options|
80
- pass_type_id = args.first || determine_pass_type_id!
81
-
82
- csr = options.csr
83
- csr ||= ask "CSR Path:"
84
- say_error "No Certificate Signing Request found at path #{csr}." and abort if not ::File.exists?(csr)
85
-
86
- result = agent.add_pass_certificate(pass_type_id, csr)
87
- say_error "Failed to configure #{pass_type_id}" and abort if not result["acknowledgement"] or result["pageError"]
88
-
89
- say_ok "Configured #{pass_type_id}. Apple is generating the certificate..."
90
-
91
- catch(:generated) do
92
- say_ok "Certificate generated and is ready to be downloaded." and abort
93
- end
94
-
95
- # Wait up to 30 seconds for certificate to be generated
96
- 6.times do
97
- throw :generated if agent.pass_type_generate["certStatus"] rescue false
98
- sleep 5
99
- end
100
-
101
- say_warning "Certificate is not generated after waiting for 30 seconds, aborting further monitoring. You might have reached the maximum number of certificates generated (5) for a pass." and abort
102
- end
103
- end
104
-
105
- command :'pass_type_ids:certificates:download' do |c|
106
- c.syntax = 'ios pass_type_ids:certificates:download PASS_TYPE_ID [--certificate_id STRING]'
107
- c.summary = 'Adds the pass certificate for pass type ID to the Provisioning Portal'
108
- c.description = ''
109
- c.option '-c', '--certificate_id ID', 'Certificate ID'
110
-
111
- c.action do |args, options|
112
- pass_type_id = args.first || determine_pass_type_id!
113
-
114
- certificate_id = options.certificate_id
115
-
116
- if filename = agent.download_pass_certificate(pass_type_id, certificate_id)
117
- say_ok "Successfully downloaded: '#{filename}'"
118
- else
119
- say_error "Could not download pass certificate"
120
- end
121
- end
122
- end
123
-
124
- private
125
-
126
- PASS_TYPE_ID_REGEXP = /^pass\.([A-Za-z0-9-]+\.?)+(\*|[^\.])$/
127
-
128
- def determine_pass_type_id!
129
- pass_type_ids = try{agent.list_pass_type_ids}
130
-
131
- case pass_type_ids.length
132
- when 0
133
- say_error "No Pass Types found." and abort
134
- when 1
135
- pass_type_id = pass_type_ids.first
136
- else
137
- pass_type_id = choose "Select a Pass Type", *pass_type_ids
138
- end
139
- end