sigh 0.9.0 → 0.10.0
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 +4 -4
- data/lib/sigh/options.rb +10 -4
- data/lib/sigh/spaceship/runner.rb +24 -16
- data/lib/sigh/version.rb +1 -1
- metadata +29 -29
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 245ffdf941239718a698805cfd99f6e1a03cbcb3
|
4
|
+
data.tar.gz: 33b44f79493291ebc37b1169e002be374328a65a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7d6cdae0e0e0a543610fd48b920dad40b9f7a13cbc0402cc4d32abbdc503a98673a29cbdbf0c3643e8a30eb96d46f5ad610f890a118200be3344508983877cbb
|
7
|
+
data.tar.gz: d08d14ccc4190533d1a3d3161b8bf95853e92c352d0b9bdcf2133b5b2561f9fb8bc230655fdcec7cdd9889cd865aa310279f7742336b7e9435db5bb4915e54ab
|
data/lib/sigh/options.rb
CHANGED
@@ -81,16 +81,22 @@ module Sigh
|
|
81
81
|
description: "The certificate name to use for new profiles, or to renew with. (e.g. \"Felix Krause\")",
|
82
82
|
optional: true),
|
83
83
|
FastlaneCore::ConfigItem.new(key: :filename,
|
84
|
-
short_option: "-
|
84
|
+
short_option: "-q",
|
85
85
|
env_name: "SIGH_PROFILE_FILE_NAME",
|
86
86
|
optional: true,
|
87
87
|
description: "Filename to use for the generated provisioning profile (must include .mobileprovision)",
|
88
88
|
verify_block: Proc.new do |value|
|
89
89
|
raise "The output name must end with .mobileprovision".red unless value.end_with?".mobileprovision"
|
90
90
|
end),
|
91
|
-
FastlaneCore::ConfigItem.new(key: :
|
92
|
-
env_name: "
|
93
|
-
description: "Skips the
|
91
|
+
FastlaneCore::ConfigItem.new(key: :skip_fetch_profiles,
|
92
|
+
env_name: "SIGH_SKIP_FETCH_PROFILES",
|
93
|
+
description: "Skips the verification of existing profiles which is useful if you have thousands of profiles",
|
94
|
+
is_string: false,
|
95
|
+
default_value: false),
|
96
|
+
FastlaneCore::ConfigItem.new(key: :skip_certificate_verification,
|
97
|
+
short_option: '-z',
|
98
|
+
env_name: "SIGH_SKIP_CERTIFICATE_VERIFICATION",
|
99
|
+
description: "Skips the verification of the certificates for every existing profiles. This will make sure the provisioning profile can be used on the local machine",
|
94
100
|
is_string: false,
|
95
101
|
default_value: false),
|
96
102
|
]
|
@@ -12,7 +12,8 @@ module Sigh
|
|
12
12
|
Spaceship.select_team
|
13
13
|
Helper.log.info "Successfully logged in"
|
14
14
|
|
15
|
-
profiles =
|
15
|
+
profiles = [] if Sigh.config[:skip_fetch_profiles]
|
16
|
+
profiles ||= fetch_profiles # download the profile if it's there
|
16
17
|
|
17
18
|
if profiles.count > 0
|
18
19
|
Helper.log.info "Found #{profiles.count} matching profile(s)".yellow
|
@@ -29,16 +30,13 @@ module Sigh
|
|
29
30
|
profile = profile.update! # assign it, as it's a new profile
|
30
31
|
end
|
31
32
|
else
|
32
|
-
Helper.log.info "No existing profiles
|
33
|
+
Helper.log.info "No existing profiles, creating a new one for you".yellow
|
33
34
|
profile = create_profile!
|
34
35
|
end
|
35
36
|
|
36
37
|
raise "Something went wrong fetching the latest profile".red unless profile
|
37
38
|
|
38
|
-
|
39
|
-
store_provisioning_id_in_environment(path)
|
40
|
-
|
41
|
-
return path
|
39
|
+
return download_profile(profile)
|
42
40
|
end
|
43
41
|
|
44
42
|
# The kind of provisioning profile we're interested in
|
@@ -55,7 +53,23 @@ module Sigh
|
|
55
53
|
|
56
54
|
# Fetches a profile matching the user's search requirements
|
57
55
|
def fetch_profiles
|
58
|
-
|
56
|
+
Helper.log.info "Fetching profiles..."
|
57
|
+
results = profile_type.find_by_bundle_id(Sigh.config[:app_identifier]).find_all { |a| a.valid? }
|
58
|
+
|
59
|
+
return results if Sigh.config[:skip_certificate_verification]
|
60
|
+
|
61
|
+
|
62
|
+
return results.find_all do |a|
|
63
|
+
# Also make sure we have the certificate installed on the local machine
|
64
|
+
installed = false
|
65
|
+
a.certificates.each do |cert|
|
66
|
+
file = Tempfile.new('cert')
|
67
|
+
file.write(cert.download_raw)
|
68
|
+
file.close
|
69
|
+
installed = true if FastlaneCore::CertChecker.is_installed?(file.path)
|
70
|
+
end
|
71
|
+
installed
|
72
|
+
end
|
59
73
|
end
|
60
74
|
|
61
75
|
# Create a new profile and return it
|
@@ -64,7 +78,7 @@ module Sigh
|
|
64
78
|
bundle_id = Sigh.config[:app_identifier]
|
65
79
|
name = Sigh.config[:provisioning_name] || [bundle_id, profile_type.pretty_type].join(' ')
|
66
80
|
|
67
|
-
unless Sigh.config[:
|
81
|
+
unless Sigh.config[:skip_fetch_profiles]
|
68
82
|
if Spaceship.provisioning_profile.all.find { |p| p.name == name }
|
69
83
|
Helper.log.error "The name '#{name}' is already taken, using another one."
|
70
84
|
name += " #{Time.now.to_i}"
|
@@ -102,7 +116,7 @@ module Sigh
|
|
102
116
|
true
|
103
117
|
end
|
104
118
|
|
105
|
-
if certificates.count > 1
|
119
|
+
if certificates.count > 1 and not Sigh.config[:development]
|
106
120
|
Helper.log.info "Found more than one code signing identity. Choosing the first one. Check out `sigh --help` to see all available options.".yellow
|
107
121
|
Helper.log.info "Available Code Signing Identities for current filters:".green
|
108
122
|
certificates.each do |c|
|
@@ -118,6 +132,7 @@ module Sigh
|
|
118
132
|
raise "Could not find a matching code signing identity for #{profile_type}. You can use cert to generate one (https://github.com/fastlane/cert)".red
|
119
133
|
end
|
120
134
|
|
135
|
+
return certificates if Sigh.config[:development] # development profiles support multiple certificates
|
121
136
|
return certificates.first
|
122
137
|
end
|
123
138
|
|
@@ -135,12 +150,5 @@ module Sigh
|
|
135
150
|
Helper.log.info "Successfully downloaded provisioning profile...".green
|
136
151
|
return output_path
|
137
152
|
end
|
138
|
-
|
139
|
-
# Store the profile ID into the environment
|
140
|
-
def store_provisioning_id_in_environment(path)
|
141
|
-
require 'sigh/profile_analyser'
|
142
|
-
udid = Sigh::ProfileAnalyser.run(path)
|
143
|
-
ENV["SIGH_UDID"] = udid if udid
|
144
|
-
end
|
145
153
|
end
|
146
154
|
end
|
data/lib/sigh/version.rb
CHANGED
metadata
CHANGED
@@ -1,153 +1,153 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sigh
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.10.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Felix Krause
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-07-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: fastlane_core
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.
|
19
|
+
version: 0.9.1
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: 0.
|
26
|
+
version: 0.9.1
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: plist
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - ~>
|
31
|
+
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: 3.1.0
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- - ~>
|
38
|
+
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: 3.1.0
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: spaceship
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- -
|
45
|
+
- - ">="
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: 0.0.
|
47
|
+
version: 0.0.14
|
48
48
|
type: :runtime
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- -
|
52
|
+
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: 0.0.
|
54
|
+
version: 0.0.14
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: bundler
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- -
|
59
|
+
- - ">="
|
60
60
|
- !ruby/object:Gem::Version
|
61
61
|
version: '0'
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- -
|
66
|
+
- - ">="
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '0'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
70
|
name: rake
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
|
-
- -
|
73
|
+
- - ">="
|
74
74
|
- !ruby/object:Gem::Version
|
75
75
|
version: '0'
|
76
76
|
type: :development
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
|
-
- -
|
80
|
+
- - ">="
|
81
81
|
- !ruby/object:Gem::Version
|
82
82
|
version: '0'
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: rspec
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
|
-
- - ~>
|
87
|
+
- - "~>"
|
88
88
|
- !ruby/object:Gem::Version
|
89
89
|
version: 3.1.0
|
90
90
|
type: :development
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
|
-
- - ~>
|
94
|
+
- - "~>"
|
95
95
|
- !ruby/object:Gem::Version
|
96
96
|
version: 3.1.0
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
98
|
name: pry
|
99
99
|
requirement: !ruby/object:Gem::Requirement
|
100
100
|
requirements:
|
101
|
-
- -
|
101
|
+
- - ">="
|
102
102
|
- !ruby/object:Gem::Version
|
103
103
|
version: '0'
|
104
104
|
type: :development
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
|
-
- -
|
108
|
+
- - ">="
|
109
109
|
- !ruby/object:Gem::Version
|
110
110
|
version: '0'
|
111
111
|
- !ruby/object:Gem::Dependency
|
112
112
|
name: yard
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|
114
114
|
requirements:
|
115
|
-
- - ~>
|
115
|
+
- - "~>"
|
116
116
|
- !ruby/object:Gem::Version
|
117
117
|
version: 0.8.7.4
|
118
118
|
type: :development
|
119
119
|
prerelease: false
|
120
120
|
version_requirements: !ruby/object:Gem::Requirement
|
121
121
|
requirements:
|
122
|
-
- - ~>
|
122
|
+
- - "~>"
|
123
123
|
- !ruby/object:Gem::Version
|
124
124
|
version: 0.8.7.4
|
125
125
|
- !ruby/object:Gem::Dependency
|
126
126
|
name: webmock
|
127
127
|
requirement: !ruby/object:Gem::Requirement
|
128
128
|
requirements:
|
129
|
-
- - ~>
|
129
|
+
- - "~>"
|
130
130
|
- !ruby/object:Gem::Version
|
131
131
|
version: 1.19.0
|
132
132
|
type: :development
|
133
133
|
prerelease: false
|
134
134
|
version_requirements: !ruby/object:Gem::Requirement
|
135
135
|
requirements:
|
136
|
-
- - ~>
|
136
|
+
- - "~>"
|
137
137
|
- !ruby/object:Gem::Version
|
138
138
|
version: 1.19.0
|
139
139
|
- !ruby/object:Gem::Dependency
|
140
140
|
name: codeclimate-test-reporter
|
141
141
|
requirement: !ruby/object:Gem::Requirement
|
142
142
|
requirements:
|
143
|
-
- -
|
143
|
+
- - ">="
|
144
144
|
- !ruby/object:Gem::Version
|
145
145
|
version: '0'
|
146
146
|
type: :development
|
147
147
|
prerelease: false
|
148
148
|
version_requirements: !ruby/object:Gem::Requirement
|
149
149
|
requirements:
|
150
|
-
- -
|
150
|
+
- - ">="
|
151
151
|
- !ruby/object:Gem::Version
|
152
152
|
version: '0'
|
153
153
|
description: Because you would rather spend your time building stuff than fighting
|
@@ -184,17 +184,17 @@ require_paths:
|
|
184
184
|
- lib
|
185
185
|
required_ruby_version: !ruby/object:Gem::Requirement
|
186
186
|
requirements:
|
187
|
-
- -
|
187
|
+
- - ">="
|
188
188
|
- !ruby/object:Gem::Version
|
189
189
|
version: 2.0.0
|
190
190
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
191
191
|
requirements:
|
192
|
-
- -
|
192
|
+
- - ">="
|
193
193
|
- !ruby/object:Gem::Version
|
194
194
|
version: '0'
|
195
195
|
requirements: []
|
196
196
|
rubyforge_project:
|
197
|
-
rubygems_version: 2.4.
|
197
|
+
rubygems_version: 2.4.6
|
198
198
|
signing_key:
|
199
199
|
specification_version: 4
|
200
200
|
summary: Because you would rather spend your time building stuff than fighting provisioning
|