fastlane-plugin-stream_actions 0.3.60 → 0.3.62

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: c56256134bd3f25211ed962cdedba26c23fa8841810e0e44aacc59dbd7838727
4
- data.tar.gz: 54b67c7dcf99f0e777d72b227a898abd32eb0d853afe7af871cf349adac257e4
3
+ metadata.gz: 0cfa09a1752b54d7444c05071aff41c0257b4e846b7f037fc1e783586d3a2755
4
+ data.tar.gz: 5714bac9e4e21a18c85a1e4d281764514d6756a31c868e70bdd5ea0e46c7e7a1
5
5
  SHA512:
6
- metadata.gz: 2843bfc29dbf02ab79d2c143296c51709d23efbc500bd746836d35700d3972cf10cb624c09f21b01cf8ecb7ab1e3fb15b2d35f171dc1ff21ea37644861607a64
7
- data.tar.gz: 56a6da0623897d4352cae0217d60af11a905b2f20f9e2b5185ebb92a3808132888efe15bd7944d414ab2c8dd7bd01a380d124fbfdf22b766d471c1ba9c82b580
6
+ metadata.gz: 7694729d49c060aa784427dec52c0b6a5285897ba9173b4b13e20e9b0f7bf167842915152998c4731cb713b1f44282442073bd4da12781d40b7f9a82e173daab
7
+ data.tar.gz: ecfc5143455143e470c4858a5114f94c582e4dc1f77e0eb355f6a71935c2aaf396efc1af6b57b442c4ec9d822e57a32cf4bc021c173164f8d629221276e469a4
@@ -0,0 +1,32 @@
1
+ module Fastlane
2
+ module Actions
3
+ class MergeMainToDevelopAction < Action
4
+ def self.run(params)
5
+ other_action.ensure_git_status_clean
6
+ sh('git checkout main')
7
+ sh('git pull origin main')
8
+ sh('git checkout origin/develop')
9
+ sh('git pull origin develop')
10
+ sh('git log develop..main')
11
+ sh('git merge main')
12
+ sh('git push origin develop')
13
+ end
14
+
15
+ #####################################################
16
+ # @!group Documentation
17
+ #####################################################
18
+
19
+ def self.description
20
+ 'Merge main branch to develop'
21
+ end
22
+
23
+ def self.available_options
24
+ []
25
+ end
26
+
27
+ def self.is_supported?(platform)
28
+ true
29
+ end
30
+ end
31
+ end
32
+ end
@@ -0,0 +1,66 @@
1
+ module Fastlane
2
+ module Actions
3
+ class MergeReleaseToMainAction < Action
4
+ def self.run(params)
5
+ other_action.ensure_git_status_clean
6
+
7
+ release_branch =
8
+ if other_action.is_ci
9
+ # This API operation needs the "admin:org" scope.
10
+ ios_team = `gh api orgs/GetStream/teams/#{params[:github_team_name]}/members -q '.[].login'`.split("\n")
11
+ UI.user_error!("#{params[:author]} is not a member of the iOS Team") unless ios_team.include?(params[:author])
12
+
13
+ other_action.current_branch
14
+ else
15
+ release_branches = sh(command: 'git branch -a').delete(' ').split("\n").grep(%r(origin/.*release/))
16
+ UI.user_error!("Expected 1 release branch, found #{release_branches.size}") if release_branches.size != 1
17
+
18
+ release_branches.first
19
+ end
20
+
21
+ UI.user_error!("`#{release_branch}`` branch does not match the release branch pattern: `release/*`") unless release_branch.start_with?('release/')
22
+
23
+ sh('git config pull.ff only')
24
+ sh('git fetch --all --tags --prune')
25
+ sh("git checkout #{release_branch}")
26
+ sh("git pull origin #{release_branch} --ff-only")
27
+ sh('git checkout main')
28
+ sh('git pull origin main --ff-only')
29
+ sh("git merge #{release_branch} --ff-only")
30
+ sh('git push origin main')
31
+
32
+ comment = "Publication of the release has been launched 👍"
33
+ UI.important(comment)
34
+ other_action.pr_comment(text: comment)
35
+ end
36
+
37
+ #####################################################
38
+ # @!group Documentation
39
+ #####################################################
40
+
41
+ def self.description
42
+ 'Merge release branch to main'
43
+ end
44
+
45
+ def self.available_options
46
+ [
47
+ FastlaneCore::ConfigItem.new(
48
+ env_name: 'USER_LOGIN',
49
+ key: :author,
50
+ description: 'Github user name',
51
+ optional: true
52
+ ),
53
+ FastlaneCore::ConfigItem.new(
54
+ key: :github_team_name,
55
+ description: 'Github team name',
56
+ default_value: 'ios-developers'
57
+ )
58
+ ]
59
+ end
60
+
61
+ def self.is_supported?(platform)
62
+ true
63
+ end
64
+ end
65
+ end
66
+ end
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module StreamActions
3
- VERSION = '0.3.60'
3
+ VERSION = '0.3.62'
4
4
  end
5
5
  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.60
4
+ version: 0.3.62
5
5
  platform: ruby
6
6
  authors:
7
7
  - GetStream
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-08-15 00:00:00.000000000 Z
11
+ date: 2024-08-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: xctest_list
@@ -238,6 +238,8 @@ files:
238
238
  - lib/fastlane/plugin/stream_actions/actions/git_status.rb
239
239
  - lib/fastlane/plugin/stream_actions/actions/install_ios_runtime.rb
240
240
  - lib/fastlane/plugin/stream_actions/actions/is_check_required.rb
241
+ - lib/fastlane/plugin/stream_actions/actions/merge_main_to_develop.rb
242
+ - lib/fastlane/plugin/stream_actions/actions/merge_release_to_main.rb
241
243
  - lib/fastlane/plugin/stream_actions/actions/pod_push_safely.rb
242
244
  - lib/fastlane/plugin/stream_actions/actions/pr_comment.rb
243
245
  - lib/fastlane/plugin/stream_actions/actions/pr_create.rb