fastlane-plugin-stream_actions 0.3.65 → 0.3.67
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/fastlane/plugin/stream_actions/actions/install_ios_runtime.rb +16 -3
- data/lib/fastlane/plugin/stream_actions/actions/pr_create.rb +7 -1
- data/lib/fastlane/plugin/stream_actions/actions/update_sdk_size_in_readme.rb +17 -5
- data/lib/fastlane/plugin/stream_actions/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 195738840bfa8ef93bd7341f13117f152343806ce2d2f522c978b4ec89131c5a
|
4
|
+
data.tar.gz: f82a547e295676312c91b5b9606be98900ed715eb5eee467323cb6dc46295e9c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 491259c4dede5907a6b31e4db56a053aaa3b0746d4b95fb4fe35fa71250b240cbd217896e11b35fafa585c4128ea55fea1ece5aa49838e515bb4e0a85db3d573
|
7
|
+
data.tar.gz: aa1b545707330ae0a59fef04e006126b0a3dfe8d198aa77236ea92757ad4eac395c1a9ccc25af9fd17bc0446377b147a8931adc65d5ad659fae7cc0fb5b5e4ab
|
@@ -9,8 +9,12 @@ module Fastlane
|
|
9
9
|
end
|
10
10
|
|
11
11
|
if simulators.empty?
|
12
|
-
|
13
|
-
|
12
|
+
if params[:tool] == 'ipsw'
|
13
|
+
sh("echo 'iOS #{params[:version]} Simulator' | ipsw download xcode --sim") if Dir['*.dmg'].first.nil?
|
14
|
+
sh("#{params[:custom_script]} #{Dir['*.dmg'].first}") if params[:custom_script]
|
15
|
+
else
|
16
|
+
sh("sudo xcodes runtimes install 'iOS #{params[:version]}'")
|
17
|
+
end
|
14
18
|
UI.success("iOS #{params[:version]} Runtime successfuly installed")
|
15
19
|
else
|
16
20
|
UI.important("iOS #{params[:version]} Runtime already exists")
|
@@ -31,9 +35,18 @@ module Fastlane
|
|
31
35
|
key: :version,
|
32
36
|
description: 'iOS Version'
|
33
37
|
),
|
38
|
+
FastlaneCore::ConfigItem.new(
|
39
|
+
key: :tool,
|
40
|
+
description: 'Which tool to use to install the runtime: ipsw or xcodes',
|
41
|
+
default_value: 'ipsw',
|
42
|
+
verify_block: proc do |tool|
|
43
|
+
UI.user_error!('Available options are `ipsw` and `xcodes`') unless ['xcodes', 'ipsw'].include?(tool)
|
44
|
+
end
|
45
|
+
),
|
34
46
|
FastlaneCore::ConfigItem.new(
|
35
47
|
key: :custom_script,
|
36
|
-
description: 'Path to custom script to install the runtime'
|
48
|
+
description: 'Path to custom script to install the runtime (might be required for ipsw)',
|
49
|
+
optional: true
|
37
50
|
)
|
38
51
|
]
|
39
52
|
end
|
@@ -4,7 +4,7 @@ module Fastlane
|
|
4
4
|
def self.run(params)
|
5
5
|
sh("git checkout -b #{params[:head_branch]}")
|
6
6
|
sh('git restore Brewfile.lock.json || true')
|
7
|
-
sh(
|
7
|
+
sh("git add #{params[:git_add]}")
|
8
8
|
sh("git commit -m '#{params[:title]}'")
|
9
9
|
other_action.push_to_git_remote(tags: false)
|
10
10
|
|
@@ -53,6 +53,12 @@ module Fastlane
|
|
53
53
|
description: 'Title',
|
54
54
|
is_string: true,
|
55
55
|
optional: false
|
56
|
+
),
|
57
|
+
FastlaneCore::ConfigItem.new(
|
58
|
+
key: :git_add,
|
59
|
+
description: 'Path that should be commited',
|
60
|
+
is_string: true,
|
61
|
+
default_value: '-A'
|
56
62
|
)
|
57
63
|
]
|
58
64
|
end
|
@@ -7,14 +7,20 @@ module Fastlane
|
|
7
7
|
params[:sizes].each do |key, value|
|
8
8
|
framework_size_kb = value
|
9
9
|
framework_size_mb = (framework_size_kb / 1024.0).round(2)
|
10
|
-
framework_size = params[:size_ext] == 'KB' ? framework_size_kb : framework_size_mb
|
10
|
+
framework_size = params[:size_ext] == 'KB' ? framework_size_kb.round(0) : framework_size_mb
|
11
11
|
readme_content.gsub!(%r{(https://img.shields.io/badge/#{key}-)(.*?)(-blue)}, "\\1#{framework_size}%20#{params[:size_ext]}\\3")
|
12
12
|
end
|
13
13
|
|
14
14
|
File.write(params[:readme_path], readme_content)
|
15
15
|
UI.success('Successfully updated the SDK size labels in README.md!')
|
16
16
|
|
17
|
-
|
17
|
+
if params[:open_pr]
|
18
|
+
other_action.pr_create(
|
19
|
+
title: params[:pr_title],
|
20
|
+
git_add: 'README.md',
|
21
|
+
head_branch: "ci/sdk-size-update-#{Time.now.to_i}"
|
22
|
+
)
|
23
|
+
end
|
18
24
|
end
|
19
25
|
|
20
26
|
#####################################################
|
@@ -39,15 +45,21 @@ module Fastlane
|
|
39
45
|
description: 'SDK sizes',
|
40
46
|
is_string: false
|
41
47
|
),
|
48
|
+
FastlaneCore::ConfigItem.new(
|
49
|
+
key: :size_ext,
|
50
|
+
description: 'SDK size extension (KB or MB)',
|
51
|
+
default_value: 'MB'
|
52
|
+
),
|
42
53
|
FastlaneCore::ConfigItem.new(
|
43
54
|
key: :open_pr,
|
44
55
|
description: 'Should a PR be opened',
|
56
|
+
optional: true,
|
45
57
|
is_string: false
|
46
58
|
),
|
47
59
|
FastlaneCore::ConfigItem.new(
|
48
|
-
key: :
|
49
|
-
description: '
|
50
|
-
default_value: '
|
60
|
+
key: :pr_title,
|
61
|
+
description: 'PR title',
|
62
|
+
default_value: '[CI] Update SDK Size'
|
51
63
|
)
|
52
64
|
]
|
53
65
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fastlane-plugin-stream_actions
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.67
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- GetStream
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-
|
11
|
+
date: 2024-09-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: xctest_list
|