fastlane-plugin-sq_ci_tools 1.0.5 → 1.0.7
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/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_build_ios_application_action.rb +1 -47
- data/lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_notify_action.rb +16 -3
- data/lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_send_max_message_action.rb +73 -0
- data/lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_send_telegram_message_action.rb +2 -2
- data/lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_setup_ios_code_sign_action.rb +94 -0
- data/lib/fastlane/plugin/sq_ci_tools/helper/sq_ci_tools_helper.rb +4 -2
- data/lib/fastlane/plugin/sq_ci_tools/options/max.rb +39 -0
- data/lib/fastlane/plugin/sq_ci_tools/options/telegram.rb +1 -1
- data/lib/fastlane/plugin/sq_ci_tools/version.rb +1 -1
- metadata +6 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 79c737af815ab4e308d76c2014439573cc6f3bce3d114b1880322b7341b292a3
|
|
4
|
+
data.tar.gz: 518b3e3802f646c765f9bac45b631d646a4b2e579e0d7aa3d0e03634d1b676d2
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: e727647f0f4d93a3d8019b6998141a5f6e052e3f36bac67fe44dc70c1d94ffdfc8da40c329d3e25eb97b29fc106c219198fcc1269411c7ead123391bfc043f69
|
|
7
|
+
data.tar.gz: a3474c0848faed06e26c554d8703e36f587a59cef80ef228c9994a5761ff0c30dcbaafce34da7652c2bc7eb8753a462e115c2e645d7c1339a48f2afc7655bfd9
|
|
@@ -8,40 +8,6 @@ module Fastlane
|
|
|
8
8
|
module Actions
|
|
9
9
|
class SqCiToolsBuildIosApplicationAction < Action
|
|
10
10
|
def self.run(params)
|
|
11
|
-
other_action.sq_ci_tools_prepare_keychain
|
|
12
|
-
|
|
13
|
-
ENV['MATCH_PASSWORD'] = params[:certificates_password]
|
|
14
|
-
|
|
15
|
-
targets = Helper::SqCiToolsHelper.get_xcodeproj_targets(params[:project_path], params[:scheme])
|
|
16
|
-
|
|
17
|
-
other_action.sync_code_signing(
|
|
18
|
-
type: params[:code_signing_type],
|
|
19
|
-
git_url: params[:certificates_repo],
|
|
20
|
-
keychain_name: params[:keychain_name],
|
|
21
|
-
keychain_password: params[:keychain_password],
|
|
22
|
-
skip_confirmation: true,
|
|
23
|
-
app_identifier: targets.map { |_, app_id| app_id },
|
|
24
|
-
force: true,
|
|
25
|
-
verbose: params[:verbose],
|
|
26
|
-
generate_apple_certs: params[:generate_apple_certs]
|
|
27
|
-
)
|
|
28
|
-
|
|
29
|
-
targets.each do |target, app_identifier|
|
|
30
|
-
Helper::SqCiToolsHelper.add_target_attributes(
|
|
31
|
-
target_name: target,
|
|
32
|
-
project_path: params[:project_path]
|
|
33
|
-
)
|
|
34
|
-
|
|
35
|
-
other_action.update_code_signing_settings(
|
|
36
|
-
use_automatic_signing: false,
|
|
37
|
-
path: params[:project_path],
|
|
38
|
-
bundle_identifier: app_identifier,
|
|
39
|
-
profile_name: lane_context[SharedValues::MATCH_PROVISIONING_PROFILE_MAPPING][app_identifier],
|
|
40
|
-
code_sign_identity: params[:code_sign_identity],
|
|
41
|
-
targets: [target],
|
|
42
|
-
build_configurations: [params[:scheme]]
|
|
43
|
-
)
|
|
44
|
-
end
|
|
45
11
|
|
|
46
12
|
project_path = params[:project_path]
|
|
47
13
|
workspace_path = params[:workspace_path]
|
|
@@ -80,7 +46,7 @@ module Fastlane
|
|
|
80
46
|
end
|
|
81
47
|
|
|
82
48
|
def self.description
|
|
83
|
-
'Generate new build of iOS application
|
|
49
|
+
'Generate new build of iOS application'
|
|
84
50
|
end
|
|
85
51
|
|
|
86
52
|
def self.details
|
|
@@ -94,18 +60,6 @@ module Fastlane
|
|
|
94
60
|
description: 'Scheme for build',
|
|
95
61
|
optional: false,
|
|
96
62
|
type: String
|
|
97
|
-
),
|
|
98
|
-
FastlaneCore::ConfigItem.new(
|
|
99
|
-
key: :verbose,
|
|
100
|
-
optional: true,
|
|
101
|
-
type: Boolean,
|
|
102
|
-
default_value: false
|
|
103
|
-
),
|
|
104
|
-
FastlaneCore::ConfigItem.new(
|
|
105
|
-
key: :generate_apple_certs,
|
|
106
|
-
optional: true,
|
|
107
|
-
type: Boolean,
|
|
108
|
-
default_value: true
|
|
109
63
|
)
|
|
110
64
|
] +
|
|
111
65
|
Options::CodeSigning.options +
|
|
@@ -11,9 +11,22 @@ module Fastlane
|
|
|
11
11
|
.map { |link| "#{link[:name] || 'Ссылка'}: #{link[:url]}" }
|
|
12
12
|
.join("\n\n")
|
|
13
13
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
14
|
+
full_message = "#{message}\n\n#{links_message}"
|
|
15
|
+
begin
|
|
16
|
+
other_action.sq_ci_tools_send_telegram_message(
|
|
17
|
+
message: full_message
|
|
18
|
+
)
|
|
19
|
+
rescue => e
|
|
20
|
+
puts "Send message via Telegram error: #{e.message}"
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
begin
|
|
24
|
+
other_action.sq_ci_tools_send_max_message(
|
|
25
|
+
message: full_message
|
|
26
|
+
)
|
|
27
|
+
rescue => e
|
|
28
|
+
puts "Send message via Max error: #{e.message}"
|
|
29
|
+
end
|
|
17
30
|
end
|
|
18
31
|
|
|
19
32
|
def self.description
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
require 'fastlane/action'
|
|
2
|
+
require 'net/http'
|
|
3
|
+
require 'json'
|
|
4
|
+
require_relative '../helper/sq_ci_tools_helper'
|
|
5
|
+
require_relative '../options/max'
|
|
6
|
+
|
|
7
|
+
module Fastlane
|
|
8
|
+
module Actions
|
|
9
|
+
class SqCiToolsSendMaxMessageAction < Action
|
|
10
|
+
def self.run(params)
|
|
11
|
+
access_token = params[:max_access_token]
|
|
12
|
+
chat_ids = params[:max_chat_ids]
|
|
13
|
+
if access_token.nil? || access_token == "" || chat_ids.nil? || chat_ids == ""
|
|
14
|
+
return
|
|
15
|
+
end
|
|
16
|
+
puts params
|
|
17
|
+
|
|
18
|
+
chat_ids.split(',').each do |chat_id|
|
|
19
|
+
uri = URI.parse("https://platform-api.max.ru")
|
|
20
|
+
|
|
21
|
+
http = Net::HTTP.new(uri.host, uri.port)
|
|
22
|
+
http.use_ssl = true
|
|
23
|
+
http.set_debug_output($stdout)
|
|
24
|
+
|
|
25
|
+
request = Net::HTTP::Post.new("/messages?chat_id=#{chat_id}")
|
|
26
|
+
request.add_field('Content-Type', 'application/json')
|
|
27
|
+
request.add_field('Authorization', access_token)
|
|
28
|
+
request.body = {
|
|
29
|
+
"text" => params[:message],
|
|
30
|
+
"format" => params[:max_format]
|
|
31
|
+
}.to_json
|
|
32
|
+
response = http.request(request)
|
|
33
|
+
|
|
34
|
+
puts response
|
|
35
|
+
puts response.message
|
|
36
|
+
puts response.body
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
|
|
40
|
+
def self.description
|
|
41
|
+
'Send message via Max'
|
|
42
|
+
end
|
|
43
|
+
|
|
44
|
+
def self.details
|
|
45
|
+
''
|
|
46
|
+
end
|
|
47
|
+
|
|
48
|
+
def self.available_options
|
|
49
|
+
[
|
|
50
|
+
FastlaneCore::ConfigItem.new(
|
|
51
|
+
key: :message,
|
|
52
|
+
description: 'Message for send',
|
|
53
|
+
optional: false,
|
|
54
|
+
type: String
|
|
55
|
+
)
|
|
56
|
+
] +
|
|
57
|
+
Options::Max.options
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
def self.return_value
|
|
61
|
+
''
|
|
62
|
+
end
|
|
63
|
+
|
|
64
|
+
def self.authors
|
|
65
|
+
['Semen Kologrivov']
|
|
66
|
+
end
|
|
67
|
+
|
|
68
|
+
def self.is_supported?(_)
|
|
69
|
+
true
|
|
70
|
+
end
|
|
71
|
+
end
|
|
72
|
+
end
|
|
73
|
+
end
|
|
@@ -21,7 +21,7 @@ module Fastlane
|
|
|
21
21
|
request = Net::HTTP::Post::Multipart.new(uri, {
|
|
22
22
|
"chat_id" => chat_id,
|
|
23
23
|
"text" => params[:message],
|
|
24
|
-
"parse_mode" => params[:
|
|
24
|
+
"parse_mode" => params[:telegram_parse_mode]
|
|
25
25
|
})
|
|
26
26
|
|
|
27
27
|
http.request(request)
|
|
@@ -29,7 +29,7 @@ module Fastlane
|
|
|
29
29
|
end
|
|
30
30
|
|
|
31
31
|
def self.description
|
|
32
|
-
'Send message via
|
|
32
|
+
'Send message via Telegram'
|
|
33
33
|
end
|
|
34
34
|
|
|
35
35
|
def self.details
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
require 'fastlane/action'
|
|
2
|
+
require_relative '../helper/sq_ci_tools_helper'
|
|
3
|
+
require_relative '../options/keychain'
|
|
4
|
+
require_relative '../options/ios_app'
|
|
5
|
+
require_relative '../options/code_signing'
|
|
6
|
+
|
|
7
|
+
module Fastlane
|
|
8
|
+
module Actions
|
|
9
|
+
class SqCiToolsSetupIosCodeSignAction < Action
|
|
10
|
+
def self.run(params)
|
|
11
|
+
other_action.sq_ci_tools_prepare_keychain
|
|
12
|
+
|
|
13
|
+
ENV['MATCH_PASSWORD'] = params[:certificates_password]
|
|
14
|
+
|
|
15
|
+
targets = Helper::SqCiToolsHelper.get_xcodeproj_targets(params[:project_path], params[:scheme])
|
|
16
|
+
|
|
17
|
+
other_action.sync_code_signing(
|
|
18
|
+
type: params[:code_signing_type],
|
|
19
|
+
git_url: params[:certificates_repo],
|
|
20
|
+
keychain_name: params[:keychain_name],
|
|
21
|
+
keychain_password: params[:keychain_password],
|
|
22
|
+
skip_confirmation: true,
|
|
23
|
+
app_identifier: targets.map { |_, app_id| app_id },
|
|
24
|
+
force: true,
|
|
25
|
+
verbose: params[:verbose],
|
|
26
|
+
generate_apple_certs: params[:generate_apple_certs]
|
|
27
|
+
)
|
|
28
|
+
|
|
29
|
+
targets.each do |target, app_identifier|
|
|
30
|
+
Helper::SqCiToolsHelper.add_target_attributes(
|
|
31
|
+
target_name: target,
|
|
32
|
+
project_path: params[:project_path]
|
|
33
|
+
)
|
|
34
|
+
|
|
35
|
+
other_action.update_code_signing_settings(
|
|
36
|
+
use_automatic_signing: false,
|
|
37
|
+
path: params[:project_path],
|
|
38
|
+
bundle_identifier: app_identifier,
|
|
39
|
+
profile_name: lane_context[SharedValues::MATCH_PROVISIONING_PROFILE_MAPPING][app_identifier],
|
|
40
|
+
code_sign_identity: params[:code_sign_identity],
|
|
41
|
+
targets: [target],
|
|
42
|
+
build_configurations: [params[:scheme]]
|
|
43
|
+
)
|
|
44
|
+
end
|
|
45
|
+
end
|
|
46
|
+
|
|
47
|
+
def self.description
|
|
48
|
+
'Setup code sign of iOS application'
|
|
49
|
+
end
|
|
50
|
+
|
|
51
|
+
def self.details
|
|
52
|
+
''
|
|
53
|
+
end
|
|
54
|
+
|
|
55
|
+
def self.available_options
|
|
56
|
+
[
|
|
57
|
+
FastlaneCore::ConfigItem.new(
|
|
58
|
+
key: :scheme,
|
|
59
|
+
description: 'Scheme for build',
|
|
60
|
+
optional: false,
|
|
61
|
+
type: String
|
|
62
|
+
),
|
|
63
|
+
FastlaneCore::ConfigItem.new(
|
|
64
|
+
key: :verbose,
|
|
65
|
+
optional: true,
|
|
66
|
+
type: Boolean,
|
|
67
|
+
default_value: false
|
|
68
|
+
),
|
|
69
|
+
FastlaneCore::ConfigItem.new(
|
|
70
|
+
key: :generate_apple_certs,
|
|
71
|
+
optional: true,
|
|
72
|
+
type: Boolean,
|
|
73
|
+
default_value: true
|
|
74
|
+
)
|
|
75
|
+
] +
|
|
76
|
+
Options::CodeSigning.options +
|
|
77
|
+
Options::Keychain.options +
|
|
78
|
+
Options::IosApp.options
|
|
79
|
+
end
|
|
80
|
+
|
|
81
|
+
def self.return_value
|
|
82
|
+
''
|
|
83
|
+
end
|
|
84
|
+
|
|
85
|
+
def self.authors
|
|
86
|
+
['Semen Kologrivov']
|
|
87
|
+
end
|
|
88
|
+
|
|
89
|
+
def self.is_supported?(_)
|
|
90
|
+
true
|
|
91
|
+
end
|
|
92
|
+
end
|
|
93
|
+
end
|
|
94
|
+
end
|
|
@@ -143,8 +143,10 @@ module Fastlane
|
|
|
143
143
|
project = Xcodeproj::Project.open(xcodeproj_path)
|
|
144
144
|
targets = {}
|
|
145
145
|
project.native_targets.each do |native_target|
|
|
146
|
-
|
|
147
|
-
|
|
146
|
+
unless native_target.product_type == "com.apple.product-type.bundle.unit-test"
|
|
147
|
+
build_configuration = native_target.build_configurations.find { |configuration| configuration.name == target_scheme }
|
|
148
|
+
targets[native_target.name] = self.resolve_recursive_build_setting(build_configuration, 'PRODUCT_BUNDLE_IDENTIFIER')
|
|
149
|
+
end
|
|
148
150
|
end
|
|
149
151
|
|
|
150
152
|
targets
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
require 'fastlane/action'
|
|
2
|
+
require 'fastlane_core/ui/ui'
|
|
3
|
+
require 'fastlane_core/configuration/config_item'
|
|
4
|
+
require 'credentials_manager/appfile_config'
|
|
5
|
+
|
|
6
|
+
module Fastlane
|
|
7
|
+
UI = FastlaneCore::UI unless Fastlane.const_defined?(:UI)
|
|
8
|
+
|
|
9
|
+
module Options
|
|
10
|
+
class Max
|
|
11
|
+
def self.options
|
|
12
|
+
[
|
|
13
|
+
FastlaneCore::ConfigItem.new(
|
|
14
|
+
key: :max_access_token,
|
|
15
|
+
env_name: 'SQ_CI_MAX_ACCESS_TOKEN',
|
|
16
|
+
description: 'Access token for Max bot',
|
|
17
|
+
optional: true,
|
|
18
|
+
type: String
|
|
19
|
+
),
|
|
20
|
+
FastlaneCore::ConfigItem.new(
|
|
21
|
+
key: :max_chat_ids,
|
|
22
|
+
env_name: 'SQ_CI_MAX_CHAT_IDS',
|
|
23
|
+
description: 'Max\'s chat ids for send message',
|
|
24
|
+
optional: true,
|
|
25
|
+
type: String
|
|
26
|
+
),
|
|
27
|
+
FastlaneCore::ConfigItem.new(
|
|
28
|
+
key: :max_format,
|
|
29
|
+
env_name: 'SQ_CI_MAX_FORMAT',
|
|
30
|
+
description: 'Max\'s format of message',
|
|
31
|
+
optional: true,
|
|
32
|
+
type: String,
|
|
33
|
+
default_value: "markdown"
|
|
34
|
+
)
|
|
35
|
+
]
|
|
36
|
+
end
|
|
37
|
+
end
|
|
38
|
+
end
|
|
39
|
+
end
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: fastlane-plugin-sq_ci_tools
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.0.
|
|
4
|
+
version: 1.0.7
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Semen Kologrivov
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2026-04-16 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: pry
|
|
@@ -153,8 +153,10 @@ files:
|
|
|
153
153
|
- lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_get_team_identifier_action.rb
|
|
154
154
|
- lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_notify_action.rb
|
|
155
155
|
- lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_prepare_keychain_action.rb
|
|
156
|
+
- lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_send_max_message_action.rb
|
|
156
157
|
- lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_send_telegram_message_action.rb
|
|
157
158
|
- lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_set_version_code_action.rb
|
|
159
|
+
- lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_setup_ios_code_sign_action.rb
|
|
158
160
|
- lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_upload_aab_to_google_play_action.rb
|
|
159
161
|
- lib/fastlane/plugin/sq_ci_tools/actions/sq_ci_tools_upload_file_to_s3_action.rb
|
|
160
162
|
- lib/fastlane/plugin/sq_ci_tools/helper/sq_ci_tools_helper.rb
|
|
@@ -163,6 +165,7 @@ files:
|
|
|
163
165
|
- lib/fastlane/plugin/sq_ci_tools/options/google_play.rb
|
|
164
166
|
- lib/fastlane/plugin/sq_ci_tools/options/ios_app.rb
|
|
165
167
|
- lib/fastlane/plugin/sq_ci_tools/options/keychain.rb
|
|
168
|
+
- lib/fastlane/plugin/sq_ci_tools/options/max.rb
|
|
166
169
|
- lib/fastlane/plugin/sq_ci_tools/options/s3.rb
|
|
167
170
|
- lib/fastlane/plugin/sq_ci_tools/options/shared.rb
|
|
168
171
|
- lib/fastlane/plugin/sq_ci_tools/options/telegram.rb
|
|
@@ -187,7 +190,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
187
190
|
- !ruby/object:Gem::Version
|
|
188
191
|
version: '0'
|
|
189
192
|
requirements: []
|
|
190
|
-
rubygems_version: 3.
|
|
193
|
+
rubygems_version: 3.5.22
|
|
191
194
|
signing_key:
|
|
192
195
|
specification_version: 4
|
|
193
196
|
summary: CI Library for sequenia's projects
|