fastlane-plugin-fastci 0.0.1 → 0.0.3
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/fastci/actions/analyze_swiftlint_action.rb +9 -5
- data/lib/fastlane/plugin/fastci/actions/detect_unused_code_action.rb +22 -18
- data/lib/fastlane/plugin/fastci/actions/package_action.rb +34 -10
- data/lib/fastlane/plugin/fastci/actions/upload_store_action.rb +1 -1
- data/lib/fastlane/plugin/fastci/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: e8e578e3c451bc288f338c816bf12606c4a2029ff4cdc77c3489950e1bb5e3d5
|
|
4
|
+
data.tar.gz: 194ee9f107f474ba5713ac7640929fe981a12cc4f8cbbbbc75018e4afe83fb3e
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 6eb4857f9e13960b13383e52516045bb6f73db9625e419e56279cbbb0e7be4be384c70bc81378cb4c2f13b9485781074c8e27f301f720675a85e39925c14fc09
|
|
7
|
+
data.tar.gz: 490f206f40a2ebaf94b80cab887d1c12d6a229640577c7aa2605c57c4c4969ff2e7e950dd0291e063ecd3968af1d04d34be0f83e35287f5c23b1836883992d7b
|
|
@@ -21,7 +21,7 @@ module Fastlane
|
|
|
21
21
|
if is_from_package == false
|
|
22
22
|
UI.message("*************| 构建项目以生成索引存储 |*************")
|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
other_action.gym(
|
|
25
25
|
clean: true,
|
|
26
26
|
silent: true,
|
|
27
27
|
workspace: Environment.workspace,
|
|
@@ -30,9 +30,7 @@ module Fastlane
|
|
|
30
30
|
buildlog_path: Constants.BUILD_LOG_DIR,
|
|
31
31
|
skip_archive: true,
|
|
32
32
|
skip_package_ipa: true
|
|
33
|
-
|
|
34
|
-
config = FastlaneCore::Configuration.create(Gym::Options.available_options, options)
|
|
35
|
-
Gym::Manager.new.work(config)
|
|
33
|
+
)
|
|
36
34
|
end
|
|
37
35
|
|
|
38
36
|
log_dir = File.expand_path(Constants.BUILD_LOG_DIR)
|
|
@@ -91,7 +89,13 @@ module Fastlane
|
|
|
91
89
|
description: "构建配置",
|
|
92
90
|
optional: true,
|
|
93
91
|
default_value: "Release",
|
|
94
|
-
type: String
|
|
92
|
+
type: String,
|
|
93
|
+
verify_block: proc do |value|
|
|
94
|
+
valid_params = ["Release", "Debug"]
|
|
95
|
+
unless valid_params.include?(value)
|
|
96
|
+
UI.user_error!("无效的编译环境: #{value}。支持的环境: #{valid_params.join(', ')}")
|
|
97
|
+
end
|
|
98
|
+
end
|
|
95
99
|
),
|
|
96
100
|
FastlaneCore::ConfigItem.new(
|
|
97
101
|
key: :commit_hash,
|
|
@@ -20,7 +20,7 @@ module Fastlane
|
|
|
20
20
|
if is_from_package == false
|
|
21
21
|
puts "*************| 构建项目以生成索引存储 |*************"
|
|
22
22
|
|
|
23
|
-
|
|
23
|
+
other_action.gym(
|
|
24
24
|
clean: true,
|
|
25
25
|
silent: true,
|
|
26
26
|
workspace: Environment.workspace,
|
|
@@ -29,9 +29,7 @@ module Fastlane
|
|
|
29
29
|
buildlog_path: Constants.BUILD_LOG_DIR,
|
|
30
30
|
skip_archive: true,
|
|
31
31
|
skip_package_ipa: true
|
|
32
|
-
|
|
33
|
-
config = FastlaneCore::Configuration.create(Gym::Options.available_options, options)
|
|
34
|
-
Gym::Manager.new.work(config)
|
|
32
|
+
)
|
|
35
33
|
end
|
|
36
34
|
|
|
37
35
|
log_dir = File.expand_path(Constants.BUILD_LOG_DIR)
|
|
@@ -72,20 +70,26 @@ module Fastlane
|
|
|
72
70
|
|
|
73
71
|
def self.available_options
|
|
74
72
|
[
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
73
|
+
FastlaneCore::ConfigItem.new(
|
|
74
|
+
key: :is_from_package,
|
|
75
|
+
description: "是否从打包流程调用",
|
|
76
|
+
optional: true,
|
|
77
|
+
default_value: false,
|
|
78
|
+
type: Boolean
|
|
79
|
+
),
|
|
80
|
+
FastlaneCore::ConfigItem.new(
|
|
81
|
+
key: :configuration,
|
|
82
|
+
description: "构建配置。默认只支持 Debug,需要支持 Release 请在 Build settings 中将 Enable Index-While-Building Functionality 设置为 Yes",
|
|
83
|
+
optional: true,
|
|
84
|
+
default_value: "Debug",
|
|
85
|
+
type: String,
|
|
86
|
+
verify_block: proc do |value|
|
|
87
|
+
valid_params = ["Release", "Debug"]
|
|
88
|
+
unless valid_params.include?(value)
|
|
89
|
+
UI.user_error!("无效的编译环境: #{value}。支持的环境: #{valid_params.join(', ')}")
|
|
90
|
+
end
|
|
91
|
+
end
|
|
92
|
+
)
|
|
89
93
|
]
|
|
90
94
|
end
|
|
91
95
|
|
|
@@ -13,6 +13,7 @@ module Fastlane
|
|
|
13
13
|
configuration = params[:configuration] || "Debug"
|
|
14
14
|
export_method = params[:export_method] || "development"
|
|
15
15
|
build = params[:build] || nil
|
|
16
|
+
version = params[:version] || nil
|
|
16
17
|
is_analyze_swiftlint = params[:is_analyze_swiftlint] || false
|
|
17
18
|
is_detect_duplicity_code = params[:is_detect_duplicity_code] || false
|
|
18
19
|
is_detect_unused_code = params[:is_detect_unused_code] || false
|
|
@@ -31,12 +32,18 @@ module Fastlane
|
|
|
31
32
|
InstallProfileAction.run({})
|
|
32
33
|
|
|
33
34
|
scheme = Environment.scheme
|
|
35
|
+
|
|
36
|
+
# 更改项目version
|
|
37
|
+
other_action.increment_version_number(
|
|
38
|
+
version_number: version
|
|
39
|
+
) if CommonHelper.is_validate_string(version)
|
|
40
|
+
|
|
34
41
|
# 更改项目build号
|
|
35
42
|
UpdateBuildNumberAction.run(
|
|
36
43
|
build: build
|
|
37
44
|
)
|
|
38
45
|
time = Time.new.strftime("%Y%m%d%H%M")
|
|
39
|
-
version = Actions::GetVersionNumberAction.run(target:
|
|
46
|
+
version = Actions::GetVersionNumberAction.run(target: Environment.target)
|
|
40
47
|
build = Actions::GetBuildNumberAction.run({})
|
|
41
48
|
# 生成ipa包的名字格式
|
|
42
49
|
ipaName = "#{Environment.scheme}_#{export_method}_#{version}_#{build}.ipa"
|
|
@@ -71,7 +78,7 @@ module Fastlane
|
|
|
71
78
|
|
|
72
79
|
UI.message("*************| 开始打包 |*************")
|
|
73
80
|
|
|
74
|
-
|
|
81
|
+
other_action.gym(
|
|
75
82
|
clean: true,
|
|
76
83
|
silent: true,
|
|
77
84
|
workspace: Environment.workspace,
|
|
@@ -84,9 +91,7 @@ module Fastlane
|
|
|
84
91
|
method: export_method,
|
|
85
92
|
provisioningProfiles: provisioningProfiles_map
|
|
86
93
|
}
|
|
87
|
-
|
|
88
|
-
config = FastlaneCore::Configuration.create(Gym::Options.available_options, options)
|
|
89
|
-
Gym::Manager.new.work(config)
|
|
94
|
+
)
|
|
90
95
|
|
|
91
96
|
UI.message("*************| 打包完成 |*************")
|
|
92
97
|
|
|
@@ -201,32 +206,51 @@ module Fastlane
|
|
|
201
206
|
key: :configuration,
|
|
202
207
|
description: "编译环境 Release or Debug",
|
|
203
208
|
optional: true,
|
|
204
|
-
default_value: "
|
|
205
|
-
type: String
|
|
209
|
+
default_value: "Debug",
|
|
210
|
+
type: String,
|
|
211
|
+
verify_block: proc do |value|
|
|
212
|
+
valid_params = ["Release", "Debug"]
|
|
213
|
+
unless valid_params.include?(value)
|
|
214
|
+
UI.user_error!("无效的编译环境: #{value}。支持的环境: #{valid_params.join(', ')}")
|
|
215
|
+
end
|
|
216
|
+
end
|
|
206
217
|
),
|
|
207
218
|
FastlaneCore::ConfigItem.new(
|
|
208
219
|
key: :export_method,
|
|
209
220
|
description: "打包方式 ad-hoc, enterprise, app-store, development",
|
|
210
221
|
optional: true,
|
|
211
222
|
default_value: "development",
|
|
223
|
+
type: String,
|
|
224
|
+
verify_block: proc do |value|
|
|
225
|
+
valid_params = ["ad-hoc", "enterprise", "app-store", "development"]
|
|
226
|
+
unless valid_params.include?(value)
|
|
227
|
+
UI.user_error!("无效的打包方式: #{value}。支持的方式: #{valid_params.join(', ')}")
|
|
228
|
+
end
|
|
229
|
+
end
|
|
230
|
+
),
|
|
231
|
+
FastlaneCore::ConfigItem.new(
|
|
232
|
+
key: :version,
|
|
233
|
+
description: "自定义 `version`。在 Xcode13 之后创建的项目,不再支持脚本修改。需要兼容请在 Build settings 中将 GENERATE_INFOPLIST_FILE 设置为 NO",
|
|
234
|
+
optional: true,
|
|
235
|
+
default_value: nil,
|
|
212
236
|
type: String
|
|
213
237
|
),
|
|
214
238
|
FastlaneCore::ConfigItem.new(
|
|
215
239
|
key: :build,
|
|
216
|
-
description: "不采取自动更新,自定义 build 号",
|
|
240
|
+
description: "不采取自动更新,自定义 `build` 号",
|
|
217
241
|
optional: true,
|
|
218
242
|
default_value: nil,
|
|
219
243
|
type: String
|
|
220
244
|
),
|
|
221
245
|
FastlaneCore::ConfigItem.new(
|
|
222
|
-
key: :
|
|
246
|
+
key: :is_analyze_swiftlint,
|
|
223
247
|
description: "是否代码分析",
|
|
224
248
|
optional: true,
|
|
225
249
|
default_value: false,
|
|
226
250
|
type: Boolean
|
|
227
251
|
),
|
|
228
252
|
FastlaneCore::ConfigItem.new(
|
|
229
|
-
key: :
|
|
253
|
+
key: :is_detect_duplicity_code,
|
|
230
254
|
description: "是否检查重复代码",
|
|
231
255
|
optional: true,
|
|
232
256
|
default_value: false,
|
|
@@ -34,7 +34,7 @@ module Fastlane
|
|
|
34
34
|
[
|
|
35
35
|
FastlaneCore::ConfigItem.new(
|
|
36
36
|
key: :release_notes,
|
|
37
|
-
description: "更新文案, 格式为 { "zh-Hans" => "
|
|
37
|
+
description: "更新文案, 格式为 { \"zh-Hans\" => \"修复问题\", \"en-US\" => \"bugfix\"} ",
|
|
38
38
|
optional: false,
|
|
39
39
|
type: Hash
|
|
40
40
|
)
|