gonative-cli 2.0.1 → 2.1.1
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/Gemfile.lock +22 -22
- data/lib/gonative/plugins/ios/release.rb +67 -1
- data/lib/gonative/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 73a5e31bef5b80d3835934ed1c1b8e92b6aeecba42ed23f5cb1bd6431c157c72
|
|
4
|
+
data.tar.gz: eafc68f276485a0706706a554c8ce65a92c9f9ead19f1eea42588f7dd3a22bb6
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: c1fa7111fce7c95b336ab328d06216016a329d020f2418c1f2f35ca3fa568af23ea0aa1ec502a8ddddc231aeb391cdbcffe1ed2d6c5e59c243ccd8be1498dd38
|
|
7
|
+
data.tar.gz: f0043f7b72dd2263f688b0b13b9d9ce2eb21ba451c81dc601a0d6e0bd44d00fe9e3aa9f9279b66b80f49a44f7947e1f3ca973908630218a55eaa03ddcee1e54c
|
data/Gemfile.lock
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
gonative-cli (2.
|
|
4
|
+
gonative-cli (2.1.0)
|
|
5
5
|
activesupport (~> 6.0)
|
|
6
6
|
aws-sdk-s3 (~> 1)
|
|
7
7
|
cocoapods (~> 1.10)
|
|
@@ -21,16 +21,16 @@ GEM
|
|
|
21
21
|
minitest (>= 5.1)
|
|
22
22
|
tzinfo (~> 2.0)
|
|
23
23
|
zeitwerk (~> 2.3)
|
|
24
|
-
addressable (2.
|
|
25
|
-
public_suffix (>= 2.0.2, <
|
|
24
|
+
addressable (2.9.0)
|
|
25
|
+
public_suffix (>= 2.0.2, < 8.0)
|
|
26
26
|
algoliasearch (1.27.5)
|
|
27
27
|
httpclient (~> 2.8, >= 2.8.3)
|
|
28
28
|
json (>= 1.5.1)
|
|
29
29
|
ast (2.4.2)
|
|
30
30
|
atomos (0.1.3)
|
|
31
31
|
aws-eventstream (1.4.0)
|
|
32
|
-
aws-partitions (1.
|
|
33
|
-
aws-sdk-core (3.
|
|
32
|
+
aws-partitions (1.1241.0)
|
|
33
|
+
aws-sdk-core (3.246.0)
|
|
34
34
|
aws-eventstream (~> 1, >= 1.3.0)
|
|
35
35
|
aws-partitions (~> 1, >= 1.992.0)
|
|
36
36
|
aws-sigv4 (~> 1.9)
|
|
@@ -38,23 +38,23 @@ GEM
|
|
|
38
38
|
bigdecimal
|
|
39
39
|
jmespath (~> 1, >= 1.6.1)
|
|
40
40
|
logger
|
|
41
|
-
aws-sdk-kms (1.
|
|
41
|
+
aws-sdk-kms (1.124.0)
|
|
42
42
|
aws-sdk-core (~> 3, >= 3.244.0)
|
|
43
43
|
aws-sigv4 (~> 1.5)
|
|
44
|
-
aws-sdk-s3 (1.
|
|
44
|
+
aws-sdk-s3 (1.220.0)
|
|
45
45
|
aws-sdk-core (~> 3, >= 3.244.0)
|
|
46
46
|
aws-sdk-kms (~> 1)
|
|
47
47
|
aws-sigv4 (~> 1.5)
|
|
48
48
|
aws-sigv4 (1.12.1)
|
|
49
49
|
aws-eventstream (~> 1, >= 1.0.2)
|
|
50
50
|
base64 (0.3.0)
|
|
51
|
-
bigdecimal (4.
|
|
51
|
+
bigdecimal (4.1.2)
|
|
52
52
|
byebug (11.1.3)
|
|
53
53
|
claide (1.1.0)
|
|
54
|
-
cocoapods (1.
|
|
54
|
+
cocoapods (1.16.2)
|
|
55
55
|
addressable (~> 2.8)
|
|
56
56
|
claide (>= 1.0.2, < 2.0)
|
|
57
|
-
cocoapods-core (= 1.
|
|
57
|
+
cocoapods-core (= 1.16.2)
|
|
58
58
|
cocoapods-deintegrate (>= 1.0.3, < 2.0)
|
|
59
59
|
cocoapods-downloader (>= 2.1, < 3.0)
|
|
60
60
|
cocoapods-plugins (>= 1.0.0, < 2.0)
|
|
@@ -68,8 +68,8 @@ GEM
|
|
|
68
68
|
molinillo (~> 0.8.0)
|
|
69
69
|
nap (~> 1.0)
|
|
70
70
|
ruby-macho (>= 2.3.0, < 3.0)
|
|
71
|
-
xcodeproj (>= 1.
|
|
72
|
-
cocoapods-core (1.
|
|
71
|
+
xcodeproj (>= 1.27.0, < 2.0)
|
|
72
|
+
cocoapods-core (1.16.2)
|
|
73
73
|
activesupport (>= 5.0, < 8)
|
|
74
74
|
addressable (~> 2.8)
|
|
75
75
|
algoliasearch (~> 1.0)
|
|
@@ -99,7 +99,7 @@ GEM
|
|
|
99
99
|
ethon (0.18.0)
|
|
100
100
|
ffi (>= 1.15.0)
|
|
101
101
|
logger
|
|
102
|
-
ffi (1.17.
|
|
102
|
+
ffi (1.17.4-arm64-darwin)
|
|
103
103
|
fourflusher (2.3.1)
|
|
104
104
|
fuzzy_match (2.0.4)
|
|
105
105
|
gh_inspector (1.1.3)
|
|
@@ -108,15 +108,15 @@ GEM
|
|
|
108
108
|
i18n (1.14.8)
|
|
109
109
|
concurrent-ruby (~> 1.0)
|
|
110
110
|
jmespath (1.6.2)
|
|
111
|
-
json (2.19.
|
|
111
|
+
json (2.19.4)
|
|
112
112
|
logger (1.7.0)
|
|
113
113
|
method_source (1.0.0)
|
|
114
|
-
minitest (6.0.
|
|
114
|
+
minitest (6.0.5)
|
|
115
115
|
drb (~> 2.0)
|
|
116
116
|
prism (~> 1.5)
|
|
117
117
|
molinillo (0.8.0)
|
|
118
118
|
mutex_m (0.3.0)
|
|
119
|
-
nanaimo (0.
|
|
119
|
+
nanaimo (0.4.0)
|
|
120
120
|
nap (1.1.0)
|
|
121
121
|
netrc (0.11.0)
|
|
122
122
|
parallel (1.20.1)
|
|
@@ -133,7 +133,7 @@ GEM
|
|
|
133
133
|
rainbow (3.0.0)
|
|
134
134
|
rake (13.0.6)
|
|
135
135
|
regexp_parser (2.1.1)
|
|
136
|
-
rexml (3.
|
|
136
|
+
rexml (3.4.4)
|
|
137
137
|
rspec (3.10.0)
|
|
138
138
|
rspec-core (~> 3.10.0)
|
|
139
139
|
rspec-expectations (~> 3.10.0)
|
|
@@ -163,18 +163,18 @@ GEM
|
|
|
163
163
|
rubocop-ast (>= 0.4.0)
|
|
164
164
|
ruby-macho (2.5.1)
|
|
165
165
|
ruby-progressbar (1.11.0)
|
|
166
|
-
typhoeus (1.
|
|
167
|
-
ethon (>= 0.
|
|
166
|
+
typhoeus (1.6.0)
|
|
167
|
+
ethon (>= 0.18.0)
|
|
168
168
|
tzinfo (2.0.6)
|
|
169
169
|
concurrent-ruby (~> 1.0)
|
|
170
170
|
unicode-display_width (2.0.0)
|
|
171
|
-
xcodeproj (1.
|
|
171
|
+
xcodeproj (1.27.0)
|
|
172
172
|
CFPropertyList (>= 2.3.3, < 4.0)
|
|
173
173
|
atomos (~> 0.1.3)
|
|
174
174
|
claide (>= 1.0.2, < 2.0)
|
|
175
175
|
colored2 (~> 3.1)
|
|
176
|
-
nanaimo (~> 0.
|
|
177
|
-
rexml (
|
|
176
|
+
nanaimo (~> 0.4.0)
|
|
177
|
+
rexml (>= 3.3.6, < 4.0)
|
|
178
178
|
zeitwerk (2.7.5)
|
|
179
179
|
|
|
180
180
|
PLATFORMS
|
|
@@ -25,6 +25,7 @@ module GoNative
|
|
|
25
25
|
|
|
26
26
|
def call
|
|
27
27
|
assert_not_published!
|
|
28
|
+
sign_frameworks!
|
|
28
29
|
zip_frameworks!
|
|
29
30
|
upload_frameworks!
|
|
30
31
|
publish_to_registry!
|
|
@@ -60,6 +61,69 @@ module GoNative
|
|
|
60
61
|
raise Error, "#{plugin_name} #{version} has already been published to the registry"
|
|
61
62
|
end
|
|
62
63
|
|
|
64
|
+
def sign_frameworks!
|
|
65
|
+
identity = codesign_identity
|
|
66
|
+
unless identity
|
|
67
|
+
Utils::UI.warning 'No codesign identity found. Set CODESIGN_IDENTITY or ensure a valid identity is in your keychain. Skipping framework signing.'
|
|
68
|
+
return
|
|
69
|
+
end
|
|
70
|
+
|
|
71
|
+
Utils::UI.info "Signing frameworks with identity: #{identity}"
|
|
72
|
+
|
|
73
|
+
Dir.glob(File.join(frameworks_dir, '*.xcframework')).each do |xcframework_path|
|
|
74
|
+
Dir.glob(File.join(xcframework_path, '**', '*.framework')).each do |framework_path|
|
|
75
|
+
Utils::UI.info "Signing #{File.basename(framework_path)}"
|
|
76
|
+
sign_command = [
|
|
77
|
+
'codesign',
|
|
78
|
+
'--sign', Shellwords.escape(identity),
|
|
79
|
+
'--timestamp',
|
|
80
|
+
'--force',
|
|
81
|
+
Shellwords.escape(framework_path)
|
|
82
|
+
].join(' ')
|
|
83
|
+
|
|
84
|
+
system(sign_command) or
|
|
85
|
+
raise Error, "Failed to sign #{framework_path}"
|
|
86
|
+
end
|
|
87
|
+
|
|
88
|
+
Utils::UI.info "Signing #{File.basename(xcframework_path)}"
|
|
89
|
+
sign_xcframework_command = [
|
|
90
|
+
'codesign',
|
|
91
|
+
'--sign', Shellwords.escape(identity),
|
|
92
|
+
'--timestamp',
|
|
93
|
+
'--force',
|
|
94
|
+
Shellwords.escape(xcframework_path)
|
|
95
|
+
].join(' ')
|
|
96
|
+
|
|
97
|
+
system(sign_xcframework_command) or
|
|
98
|
+
raise Error, "Failed to sign #{xcframework_path}"
|
|
99
|
+
end
|
|
100
|
+
end
|
|
101
|
+
|
|
102
|
+
def codesign_identity
|
|
103
|
+
@codesign_identity ||= ENV.fetch('CODESIGN_IDENTITY') do
|
|
104
|
+
output = `security find-identity -v -p codesigning 2>/dev/null`
|
|
105
|
+
match = output.match(/^\s*\d+\)\s+\S+\s+"([^"]+)"/)
|
|
106
|
+
match[1] if match
|
|
107
|
+
end
|
|
108
|
+
end
|
|
109
|
+
|
|
110
|
+
alias signing_identity codesign_identity
|
|
111
|
+
|
|
112
|
+
def registry_signing_options
|
|
113
|
+
key_path = ENV['SPM_SIGNING_KEY_PATH']
|
|
114
|
+
cert_path = ENV['SPM_SIGNING_CERT_PATH']
|
|
115
|
+
|
|
116
|
+
if key_path && cert_path
|
|
117
|
+
return " --private-key-path #{Shellwords.escape(key_path)}" \
|
|
118
|
+
" --cert-chain-paths #{Shellwords.escape(cert_path)}"
|
|
119
|
+
end
|
|
120
|
+
|
|
121
|
+
identity = signing_identity
|
|
122
|
+
return " --signing-identity #{Shellwords.escape(identity)}" if identity
|
|
123
|
+
|
|
124
|
+
''
|
|
125
|
+
end
|
|
126
|
+
|
|
63
127
|
def frameworks_dir
|
|
64
128
|
File.join(project_root, 'Frameworks')
|
|
65
129
|
end
|
|
@@ -176,9 +240,11 @@ module GoNative
|
|
|
176
240
|
# Update the staged Package.swift with real URLs and checksums
|
|
177
241
|
update_package_swift!(staging_dir)
|
|
178
242
|
|
|
243
|
+
signing_opts = registry_signing_options
|
|
244
|
+
|
|
179
245
|
FileUtils.cd(staging_dir) do
|
|
180
246
|
system "swift package-registry publish #{package_identity} #{version}" \
|
|
181
|
-
" --registry-url #{registry_url}" or
|
|
247
|
+
" --registry-url #{registry_url}#{signing_opts}" or
|
|
182
248
|
raise Error, 'Failed to publish to SPM registry'
|
|
183
249
|
end
|
|
184
250
|
end
|
data/lib/gonative/version.rb
CHANGED