fastlane-plugin-fastci 0.0.13 → 0.0.14

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
  SHA256:
3
- metadata.gz: 9cdc516b58bb5440ca5f24a496c5725a231a19d1986cf26d2ae4f914f2a0bc04
4
- data.tar.gz: eea7c54fa1c128f082a4d289569b6ddbd191714cb25106365165b7242ee4805f
3
+ metadata.gz: bc2ff5d0f6cd3421e117ad30b091e5138c34b8438d967fcb035cd2383f750041
4
+ data.tar.gz: c41fa51ca79664423bc1b89b5f8248c7963a41db054095e4226aa31a9fc69d1d
5
5
  SHA512:
6
- metadata.gz: 7851b7b24d473f10d817a365829539e10c6fccbce662a5d4be9d686d2b543f15fb7f80b4f017922b215f630ca5dccda8bccdbb60f1363ab4ef5f60e3949d974c
7
- data.tar.gz: 878f45bebf4ef2030591a709300cbdaa6e5b01aeed0b5a6b26ad60543a3303827e0fa0c373f1889615549db2abeb18eab3e07480a57844f8383e6425aaef5932
6
+ metadata.gz: 132de4650487971ef9c853787d5328ff4ac40f270ecb018abd0d42c1a730af4d3ff1a5b77a52d80880137cc206ab245a8ce5422b6f8aebfd5ce19226ffe20a94
7
+ data.tar.gz: 25cba3b8703900c008547f3a2276a8412a5d7df53556cd81c57a4ad7f07e63cff433e13690ccafe2729ac0a967dc56ccb9d22297fe867ef8e0fb52591d013de1
@@ -41,7 +41,14 @@ module Fastlane
41
41
  analyze_file = File.expand_path(Constants.SWIFTLINT_ANALYZE_FILE)
42
42
 
43
43
  if is_all
44
- sh "swiftlint analyze --config #{yml_file} --compiler-log-path #{log_file} --force-exclude > #{analyze_file} || true"
44
+ sh("
45
+ swiftlint analyze \
46
+ --quiet \
47
+ --config #{yml_file} \
48
+ --compiler-log-path #{log_file} \
49
+ --force-exclude \
50
+ > #{analyze_file} || true
51
+ ")
45
52
  else
46
53
  commit_hash = params[:commit_hash] || read_cached_txt(Constants.COMMIT_HASH_FILE)
47
54
  swift_files = CommonHelper.get_git_modified_swift_files(commit_hash)
@@ -52,7 +59,15 @@ module Fastlane
52
59
  end
53
60
 
54
61
  files_to_analyze = swift_files.join(" ")
55
- sh "swiftlint analyze --config #{yml_file} --compiler-log-path #{log_file} #{files_to_analyze} --force-exclude > #{analyze_file} || true"
62
+ sh("
63
+ swiftlint analyze \
64
+ --quiet \
65
+ --config #{yml_file} \
66
+ --compiler-log-path #{log_file} \
67
+ #{files_to_analyze} \
68
+ --force-exclude \
69
+ > #{analyze_file} || true
70
+ ")
56
71
  end
57
72
 
58
73
  # 输出代码分析报告
@@ -7,7 +7,7 @@ module Fastlane
7
7
  class UploadStoreAction < Action
8
8
  def self.run(params)
9
9
 
10
- release_notes = JSON.parse(params[:release_notes] || "") rescue ""
10
+ release_notes = JSON.parse(params[:release_notes] || "") rescue nil
11
11
 
12
12
  other_action.app_store_connect_api_key(
13
13
  key_id: Environment.connect_key_id,
@@ -24,16 +24,24 @@ module Fastlane
24
24
  )
25
25
  else
26
26
  UI.message("*************| 开始上传 AppStore |*************")
27
- other_action.upload_to_app_store(
27
+
28
+ # 构建上传参数,只有当 release_notes 有效时才添加
29
+ upload_options = {
28
30
  skip_metadata: false,
29
31
  skip_screenshots: true,
30
32
  run_precheck_before_submit: false,
31
33
  precheck_include_in_app_purchases: false,
32
34
  force: true,
33
35
  submit_for_review: false,
34
- automatic_release: false,
35
- release_notes: release_notes
36
- )
36
+ automatic_release: false
37
+ }
38
+
39
+ # 只有当 release_notes 不为 nil 且不为空时才添加
40
+ if release_notes && !release_notes.empty?
41
+ upload_options[:release_notes] = release_notes
42
+ end
43
+
44
+ other_action.upload_to_app_store(upload_options)
37
45
  end
38
46
  end
39
47
 
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module Fastci
3
- VERSION = "0.0.13"
3
+ VERSION = "0.0.14"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-fastci
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.13
4
+ version: 0.0.14
5
5
  platform: ruby
6
6
  authors:
7
7
  - watermelon