cupertino 0.9.3 → 0.9.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 21733a68969f6c70405b747bd628ac083979575d
|
4
|
+
data.tar.gz: d95409fb5a8315b9f10e1bf5f848b8b44166df7b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d0066314c6e3b32d802a4e3198e8cf9d9d18a004fc30e9ec4cdf6ddd59880b110048959370d10d57e660b22691dd00d9b75e068e25e6c45ae20f3ddef5c6ad59
|
7
|
+
data.tar.gz: 12a222d2a39db4611ad34c1b6e6b1c3841da389a820ff78282fa3058ab0f30c99f10517cbb1a4489226b962f5e0c7aec4787e762d64bee29dec8e4a913f1beeb
|
data/Gemfile.lock
CHANGED
data/cupertino-0.9.3.gem
ADDED
Binary file
|
data/cupertino-0.9.4.gem
ADDED
Binary file
|
@@ -34,7 +34,7 @@ command :'certificates:download' do |c|
|
|
34
34
|
c.syntax = 'ios certificates:download [development|distribution]'
|
35
35
|
c.summary = 'Downloads the Certificates'
|
36
36
|
c.description = ''
|
37
|
-
|
37
|
+
|
38
38
|
c.action do |args, options|
|
39
39
|
type = args.first.downcase.to_sym rescue nil
|
40
40
|
certificates = try{agent.list_certificates(type ||= :development)}
|
@@ -6,8 +6,8 @@ command :'profiles:list' do |c|
|
|
6
6
|
c.option '--type [TYPE]', [:development, :distribution], "Type of profile (development or distribution; defaults to development)"
|
7
7
|
|
8
8
|
c.action do |args, options|
|
9
|
-
type = options.type.downcase.to_sym if options.type
|
10
|
-
profiles = try{agent.list_profiles(type
|
9
|
+
type = (options.type.downcase.to_sym if options.type) || :development
|
10
|
+
profiles = try{agent.list_profiles(type)}
|
11
11
|
|
12
12
|
say_warning "No #{type} provisioning profiles found." and abort if profiles.empty?
|
13
13
|
|
@@ -40,16 +40,13 @@ command :'profiles:download' do |c|
|
|
40
40
|
c.option '--type [TYPE]', [:development, :distribution], "Type of profile (development or distribution; defaults to development)"
|
41
41
|
|
42
42
|
c.action do |args, options|
|
43
|
-
type = options.type.downcase.to_sym if options.type
|
44
|
-
profiles = try{agent.list_profiles(type
|
43
|
+
type = (options.type.downcase.to_sym if options.type) || :development
|
44
|
+
profiles = try{agent.list_profiles(type)}
|
45
45
|
profiles = profiles.select{|profile| profile.status == 'Active'}
|
46
46
|
|
47
47
|
say_warning "No active #{type} profiles found." and abort if profiles.empty?
|
48
48
|
|
49
|
-
|
50
|
-
unless profile = profiles.detect{|p| p.name == name}
|
51
|
-
profile = choose "Select a profile to download:", *profiles
|
52
|
-
end
|
49
|
+
profile = profiles.find{|p| p.name == args.join(" ")} || choose("Select a profile:", *profiles)
|
53
50
|
|
54
51
|
if filename = agent.download_profile(profile)
|
55
52
|
say_ok "Successfully downloaded: '#{filename}'"
|
@@ -67,8 +64,8 @@ command :'profiles:download:all' do |c|
|
|
67
64
|
c.option '--type [TYPE]', [:development, :distribution], "Type of profile (development or distribution; defaults to development)"
|
68
65
|
|
69
66
|
c.action do |args, options|
|
70
|
-
type = options.type.downcase.to_sym if options.type
|
71
|
-
profiles = try{agent.list_profiles(type
|
67
|
+
type = (options.type.downcase.to_sym if options.type) || :development
|
68
|
+
profiles = try{agent.list_profiles(type)}
|
72
69
|
profiles = profiles.select{|profile| profile.status == 'Active'}
|
73
70
|
|
74
71
|
say_warning "No active #{type} profiles found." and abort if profiles.empty?
|
@@ -83,21 +80,20 @@ command :'profiles:download:all' do |c|
|
|
83
80
|
end
|
84
81
|
|
85
82
|
command :'profiles:manage:devices' do |c|
|
86
|
-
c.syntax = 'ios profiles:manage:devices'
|
83
|
+
c.syntax = 'ios profiles:manage:devices [PROFILE_NAME]'
|
87
84
|
c.summary = 'Manage active devices for a development provisioning profile'
|
88
85
|
c.description = ''
|
89
86
|
|
90
87
|
c.option '--type [TYPE]', [:development, :distribution], "Type of profile (development or distribution; defaults to development)"
|
91
88
|
|
92
89
|
c.action do |args, options|
|
93
|
-
type = options.type.downcase.to_sym if options.type
|
94
|
-
profiles = try{agent.list_profiles(type
|
95
|
-
|
90
|
+
type = (options.type.downcase.to_sym if options.type) || :development
|
91
|
+
profiles = try{agent.list_profiles(type)}
|
96
92
|
profiles.delete_if{|profile| profile.status == "Invalid"}
|
97
93
|
|
98
94
|
say_warning "No valid #{type} provisioning profiles found." and abort if profiles.empty?
|
99
95
|
|
100
|
-
profile = choose
|
96
|
+
profile = profiles.find{|p| p.name == args.first} || choose("Select a profile:", *profiles)
|
101
97
|
|
102
98
|
agent.manage_devices_for_profile(profile) do |on, off|
|
103
99
|
lines = ["# Comment / Uncomment Devices to Turn Off / On for Provisioning Profile"]
|
@@ -125,30 +121,35 @@ end
|
|
125
121
|
alias_command :'profiles:devices', :'profiles:manage:devices'
|
126
122
|
|
127
123
|
command :'profiles:manage:devices:add' do |c|
|
128
|
-
c.syntax = 'ios profiles:manage:devices:add PROFILE_NAME DEVICE_NAME=DEVICE_ID [...]'
|
124
|
+
c.syntax = 'ios profiles:manage:devices:add [PROFILE_NAME] DEVICE_NAME=DEVICE_ID [...]'
|
129
125
|
c.summary = 'Add active devices to a Provisioning Profile'
|
130
126
|
c.description = ''
|
131
127
|
|
132
128
|
c.action do |args, options|
|
133
129
|
profiles = try{agent.list_profiles(:development) + agent.list_profiles(:distribution)}
|
134
|
-
profile = profiles.find
|
130
|
+
profile = profiles.find{|p| p.name == args.first} || choose("Select a profile:", *profiles)
|
135
131
|
|
136
|
-
|
132
|
+
names = args[1..-1].select{|arg| /\=/ === arg}.collect{|arg| arg.sub /\=.*/, ''}
|
133
|
+
devices = []
|
137
134
|
|
138
135
|
agent.manage_devices_for_profile(profile) do |on, off|
|
139
|
-
names
|
140
|
-
|
136
|
+
names.each_with_index do |name, idx|
|
137
|
+
next if idx == 0 and name == profile.name
|
141
138
|
|
142
|
-
names.each do |name|
|
143
139
|
device = (on + off).detect{|d| d.name === name}
|
144
|
-
say_warning "No device named #{name} was found."
|
140
|
+
say_warning "No device named #{name} was found." unless device
|
145
141
|
devices << Device.new(name, device.udid)
|
146
142
|
end
|
147
143
|
|
148
144
|
on + devices
|
149
145
|
end
|
150
146
|
|
151
|
-
|
147
|
+
case devices.length
|
148
|
+
when 0
|
149
|
+
say_warning "No devices were added"
|
150
|
+
else
|
151
|
+
say_ok "Successfully added #{pluralize(devices.length, 'device', 'devices')} to #{profile}."
|
152
|
+
end
|
152
153
|
end
|
153
154
|
end
|
154
155
|
|
@@ -161,17 +162,23 @@ command :'profiles:manage:devices:remove' do |c|
|
|
161
162
|
|
162
163
|
c.action do |args, options|
|
163
164
|
profiles = try{agent.list_profiles(:development) + agent.list_profiles(:distribution)}
|
164
|
-
profile = profiles.find
|
165
|
+
profile = profiles.find{|p| p.name == args.first} || choose("Select a profile:", *profiles)
|
165
166
|
|
166
167
|
say_warning "No provisioning profiles named #{args.first} were found." and abort unless profile
|
167
168
|
|
168
|
-
names = args
|
169
|
+
names = args.collect{|arg| arg.gsub /\=.*/, ''}
|
169
170
|
|
171
|
+
devices = []
|
170
172
|
agent.manage_devices_for_profile(profile) do |on, off|
|
171
|
-
on.delete_if{|
|
173
|
+
devices = on.delete_if{|device| names.include?(device.name)}
|
172
174
|
end
|
173
175
|
|
174
|
-
|
176
|
+
case devices.length
|
177
|
+
when 0
|
178
|
+
say_warning "No devices were removed"
|
179
|
+
else
|
180
|
+
say_ok "Successfully removed #{pluralize(devices.length, 'device', 'devices')} from #{profile}."
|
181
|
+
end
|
175
182
|
end
|
176
183
|
end
|
177
184
|
|
data/lib/cupertino/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cupertino
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.9.
|
4
|
+
version: 0.9.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mattt Thompson
|
@@ -157,6 +157,8 @@ executables:
|
|
157
157
|
extensions: []
|
158
158
|
extra_rdoc_files: []
|
159
159
|
files:
|
160
|
+
- ./cupertino-0.9.3.gem
|
161
|
+
- ./cupertino-0.9.4.gem
|
160
162
|
- ./cupertino.gemspec
|
161
163
|
- ./Gemfile
|
162
164
|
- ./Gemfile.lock
|