fastlane-plugin-wpmreleasetoolkit 1.4.0 → 2.3.0
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/wpmreleasetoolkit/actions/android/android_betabuild_prechecks.rb +19 -19
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_build_prechecks.rb +5 -10
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_bump_version_beta.rb +9 -16
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_bump_version_final_release.rb +8 -15
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_bump_version_hotfix.rb +6 -12
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_bump_version_release.rb +20 -20
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_codefreeze_prechecks.rb +13 -13
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_completecodefreeze_prechecks.rb +2 -8
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_current_branch_is_hotfix.rb +1 -7
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_download_file_by_version.rb +1 -1
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_finalize_prechecks.rb +2 -6
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_get_alpha_version.rb +1 -7
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_get_app_version.rb +1 -7
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_get_release_version.rb +1 -7
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_tag_build.rb +2 -8
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/common/check_translation_progress.rb +1 -1
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/common/comment_on_pr.rb +89 -0
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/common/create_release_action.rb +3 -1
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_betabuild_prechecks.rb +8 -2
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_bump_version_release.rb +10 -5
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_codefreeze_prechecks.rb +10 -4
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_generate_strings_file_from_code.rb +115 -0
- data/lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_localize_project.rb +5 -6
- data/lib/fastlane/plugin/wpmreleasetoolkit/helper/an_metadata_update_helper.rb +1 -1
- data/lib/fastlane/plugin/wpmreleasetoolkit/helper/android/android_git_helper.rb +1 -1
- data/lib/fastlane/plugin/wpmreleasetoolkit/helper/android/android_version_helper.rb +33 -68
- data/lib/fastlane/plugin/wpmreleasetoolkit/helper/git_helper.rb +5 -0
- data/lib/fastlane/plugin/wpmreleasetoolkit/helper/github_helper.rb +48 -8
- data/lib/fastlane/plugin/wpmreleasetoolkit/helper/interactive_prompt_reminder.rb +93 -0
- data/lib/fastlane/plugin/wpmreleasetoolkit/version.rb +1 -1
- metadata +13 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a9f3fcba792147f476a814f8f67f2620b5c6740497754eb033e2919e25dd3168
|
4
|
+
data.tar.gz: 25077b056c019d26adad929b9fffbf942c23f22a60f66892905de241b624b2bb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d81b6b46eb930e0d15922c08eeea4314e9af06ef356b8dad207a6c76bec0793c1cf4e3c00507c16666170d3f6fe56960c9b3883ca567890e867fb1b50d064adf
|
7
|
+
data.tar.gz: a92daf218f3ec9094a0d26edd0f6be4a6062c83609618ccdae26980afe9efd8b10ec6e4192f73290526106f93b6b352c94e55e3944053806ea0d06548ed155c7
|
@@ -8,24 +8,23 @@ module Fastlane
|
|
8
8
|
require_relative '../../helper/android/android_version_helper'
|
9
9
|
require_relative '../../helper/android/android_git_helper'
|
10
10
|
|
11
|
-
# Checkout
|
12
|
-
|
13
|
-
|
14
|
-
app = params[:app]
|
11
|
+
# Checkout default branch and update
|
12
|
+
default_branch = params[:default_branch]
|
13
|
+
Fastlane::Helper::GitHelper.checkout_and_pull(default_branch)
|
15
14
|
|
16
15
|
# Check versions
|
17
|
-
release_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
18
|
-
message = "
|
19
|
-
alpha_release_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
20
|
-
message << "
|
16
|
+
release_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
17
|
+
message = "The following current version has been detected: #{release_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}\n"
|
18
|
+
alpha_release_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
19
|
+
message << "The following Alpha version has been detected: #{alpha_release_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}\n" unless alpha_release_version.nil?
|
21
20
|
|
22
21
|
# Check branch
|
23
|
-
app_version = Fastlane::Helper::Android::VersionHelper.get_public_version
|
22
|
+
app_version = Fastlane::Helper::Android::VersionHelper.get_public_version
|
24
23
|
UI.user_error!("#{message}Release branch for version #{app_version} doesn't exist. Abort.") unless !params[:base_version].nil? || Fastlane::Helper::GitHelper.checkout_and_pull(release: app_version)
|
25
24
|
|
26
25
|
# Check user overwrite
|
27
26
|
unless params[:base_version].nil?
|
28
|
-
overwrite_version = get_user_build_version(
|
27
|
+
overwrite_version = get_user_build_version(version: params[:base_version], message: message)
|
29
28
|
release_version = overwrite_version[0]
|
30
29
|
alpha_release_version = overwrite_version[1]
|
31
30
|
end
|
@@ -49,11 +48,11 @@ module Fastlane
|
|
49
48
|
[next_beta_version, next_alpha_version]
|
50
49
|
end
|
51
50
|
|
52
|
-
def self.get_user_build_version(
|
53
|
-
UI.user_error!("
|
54
|
-
release_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
55
|
-
message << "
|
56
|
-
alpha_release_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
51
|
+
def self.get_user_build_version(version:, message:)
|
52
|
+
UI.user_error!("Release branch for version #{version} doesn't exist. Abort.") unless Fastlane::Helper::GitHelper.checkout_and_pull(release: version)
|
53
|
+
release_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
54
|
+
message << "Looking at branch release/#{version} as requested by user. Detected version: #{release_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}.\n"
|
55
|
+
alpha_release_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
57
56
|
message << "and Alpha Version: #{alpha_release_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}\n" unless alpha_release_version.nil?
|
58
57
|
[release_version, alpha_release_version]
|
59
58
|
end
|
@@ -82,10 +81,11 @@ module Fastlane
|
|
82
81
|
description: 'Skips confirmation',
|
83
82
|
is_string: false, # true: verifies the input is a string, false: every kind of value
|
84
83
|
default_value: false), # the default value if the user didn't provide one
|
85
|
-
FastlaneCore::ConfigItem.new(key: :
|
86
|
-
env_name: '
|
87
|
-
description: '
|
88
|
-
|
84
|
+
FastlaneCore::ConfigItem.new(key: :default_branch,
|
85
|
+
env_name: 'FL_RELEASE_TOOLKIT_DEFAULT_BRANCH',
|
86
|
+
description: 'Default branch of the repository',
|
87
|
+
type: String,
|
88
|
+
default_value: Fastlane::Helper::GitHelper::DEFAULT_GIT_BRANCH),
|
89
89
|
]
|
90
90
|
end
|
91
91
|
|
@@ -9,16 +9,15 @@ module Fastlane
|
|
9
9
|
|
10
10
|
Fastlane::Helper::GitHelper.ensure_on_branch!('release') unless other_action.is_ci()
|
11
11
|
|
12
|
-
app = params[:app]
|
13
12
|
message = ''
|
14
|
-
beta_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
15
|
-
alpha_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
13
|
+
beta_version = Fastlane::Helper::Android::VersionHelper.get_release_version unless !params[:beta] && !params[:final]
|
14
|
+
alpha_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version if params[:alpha]
|
16
15
|
|
17
16
|
UI.user_error!("Can't build a final release out of this branch because it's configured as a beta release!") if params[:final] && Fastlane::Helper::Android::VersionHelper.is_beta_version?(beta_version)
|
18
17
|
|
19
|
-
message << "
|
20
|
-
message << "
|
21
|
-
message << "
|
18
|
+
message << "Building version #{beta_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}(#{beta_version[Fastlane::Helper::Android::VersionHelper::VERSION_CODE]}) (for upload to Release Channel)\n" if params[:final]
|
19
|
+
message << "Building version #{beta_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}(#{beta_version[Fastlane::Helper::Android::VersionHelper::VERSION_CODE]}) (for upload to Beta Channel)\n" if params[:beta]
|
20
|
+
message << "Building version #{alpha_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}(#{alpha_version[Fastlane::Helper::Android::VersionHelper::VERSION_CODE]}) (for upload to Alpha Channel)\n" if params[:alpha]
|
22
21
|
|
23
22
|
if params[:skip_confirm]
|
24
23
|
UI.message(message)
|
@@ -64,10 +63,6 @@ module Fastlane
|
|
64
63
|
description: 'True if this is for a final build',
|
65
64
|
is_string: false,
|
66
65
|
default_value: false),
|
67
|
-
FastlaneCore::ConfigItem.new(key: :app,
|
68
|
-
env_name: 'PROJECT_NAME',
|
69
|
-
description: 'The name of the app to get the release version for',
|
70
|
-
is_string: true), # true: verifies the input is a string, false: every kind of value
|
71
66
|
]
|
72
67
|
end
|
73
68
|
|
@@ -8,22 +8,21 @@ module Fastlane
|
|
8
8
|
require_relative '../../helper/android/android_version_helper'
|
9
9
|
|
10
10
|
Fastlane::Helper::GitHelper.ensure_on_branch!('release')
|
11
|
-
app = params[:app]
|
12
11
|
|
13
|
-
current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
14
|
-
current_version_alpha = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
12
|
+
current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
13
|
+
current_version_alpha = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
15
14
|
new_version_beta = Fastlane::Helper::Android::VersionHelper.calc_next_beta_version(current_version, current_version_alpha)
|
16
15
|
new_version_alpha = current_version_alpha.nil? ? nil : Fastlane::Helper::Android::VersionHelper.calc_next_alpha_version(new_version_beta, current_version_alpha)
|
17
16
|
|
18
17
|
vname = Fastlane::Helper::Android::VersionHelper::VERSION_NAME
|
19
18
|
vcode = Fastlane::Helper::Android::VersionHelper::VERSION_CODE
|
20
|
-
UI.message("Current version
|
21
|
-
UI.message("Current alpha version
|
22
|
-
UI.message("New beta version
|
23
|
-
UI.message("New alpha version
|
19
|
+
UI.message("Current version: #{current_version[vname]}(#{current_version[vcode]})")
|
20
|
+
UI.message("Current alpha version: #{current_version_alpha[vname]}(#{current_version_alpha[vcode]})") unless current_version_alpha.nil?
|
21
|
+
UI.message("New beta version: #{new_version_beta[vname]}(#{new_version_beta[vcode]})")
|
22
|
+
UI.message("New alpha version: #{new_version_alpha[vname]}(#{new_version_alpha[vcode]})") unless current_version_alpha.nil?
|
24
23
|
|
25
24
|
UI.message 'Updating app version...'
|
26
|
-
Fastlane::Helper::Android::VersionHelper.update_versions(
|
25
|
+
Fastlane::Helper::Android::VersionHelper.update_versions(new_version_beta, new_version_alpha)
|
27
26
|
UI.message 'Done!'
|
28
27
|
|
29
28
|
Fastlane::Helper::Android::GitHelper.commit_version_bump()
|
@@ -34,21 +33,15 @@ module Fastlane
|
|
34
33
|
#####################################################
|
35
34
|
|
36
35
|
def self.description
|
37
|
-
'Bumps the version of the app for a new beta.
|
36
|
+
'Bumps the version of the app for a new beta.'
|
38
37
|
end
|
39
38
|
|
40
39
|
def self.details
|
41
|
-
'Bumps the version of the app for a new beta.
|
40
|
+
'Bumps the version of the app for a new beta.'
|
42
41
|
end
|
43
42
|
|
44
43
|
def self.available_options
|
45
44
|
# Define all options your action supports.
|
46
|
-
[
|
47
|
-
FastlaneCore::ConfigItem.new(key: :app,
|
48
|
-
env_name: 'PROJECT_NAME',
|
49
|
-
description: 'The name of the app to get the release version for',
|
50
|
-
is_string: true), # true: verifies the input is a string, false: every kind of value
|
51
|
-
]
|
52
45
|
end
|
53
46
|
|
54
47
|
def self.output
|
data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_bump_version_final_release.rb
CHANGED
@@ -8,20 +8,19 @@ module Fastlane
|
|
8
8
|
require_relative '../../helper/android/android_version_helper'
|
9
9
|
|
10
10
|
Fastlane::Helper::GitHelper.ensure_on_branch!('release')
|
11
|
-
app = params[:app]
|
12
11
|
|
13
|
-
current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
14
|
-
current_version_alpha = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
12
|
+
current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
13
|
+
current_version_alpha = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
15
14
|
final_version = Fastlane::Helper::Android::VersionHelper.calc_final_release_version(current_version, current_version_alpha)
|
16
15
|
|
17
16
|
vname = Fastlane::Helper::Android::VersionHelper::VERSION_NAME
|
18
17
|
vcode = Fastlane::Helper::Android::VersionHelper::VERSION_CODE
|
19
|
-
UI.message("Current version
|
20
|
-
UI.message("Current alpha version
|
21
|
-
UI.message("New release version
|
18
|
+
UI.message("Current version: #{current_version[vname]}(#{current_version[vcode]})")
|
19
|
+
UI.message("Current alpha version: #{current_version_alpha[vname]}(#{current_version_alpha[vcode]})") unless current_version_alpha.nil?
|
20
|
+
UI.message("New release version: #{final_version[vname]}(#{final_version[vcode]})")
|
22
21
|
|
23
22
|
UI.message 'Updating app version...'
|
24
|
-
Fastlane::Helper::Android::VersionHelper.update_versions(
|
23
|
+
Fastlane::Helper::Android::VersionHelper.update_versions(final_version, current_version_alpha)
|
25
24
|
UI.message 'Done!'
|
26
25
|
|
27
26
|
Fastlane::Helper::Android::GitHelper.commit_version_bump()
|
@@ -32,21 +31,15 @@ module Fastlane
|
|
32
31
|
#####################################################
|
33
32
|
|
34
33
|
def self.description
|
35
|
-
'Bumps the version of the app for a new beta.
|
34
|
+
'Bumps the version of the app for a new beta.'
|
36
35
|
end
|
37
36
|
|
38
37
|
def self.details
|
39
|
-
'Bumps the version of the app for a new beta.
|
38
|
+
'Bumps the version of the app for a new beta.'
|
40
39
|
end
|
41
40
|
|
42
41
|
def self.available_options
|
43
42
|
# Define all options your action supports.
|
44
|
-
[
|
45
|
-
FastlaneCore::ConfigItem.new(key: :app,
|
46
|
-
env_name: 'PROJECT_NAME',
|
47
|
-
description: 'The name of the app to get the release version for',
|
48
|
-
is_string: true), # true: verifies the input is a string, false: every kind of value
|
49
|
-
]
|
50
43
|
end
|
51
44
|
|
52
45
|
def self.authors
|
@@ -7,20 +7,18 @@ module Fastlane
|
|
7
7
|
require_relative '../../helper/android/android_git_helper'
|
8
8
|
Fastlane::Helper::GitHelper.create_branch("release/#{params[:version_name]}", from: params[:previous_version_name])
|
9
9
|
|
10
|
-
|
11
|
-
|
12
|
-
current_version = Fastlane::Helper::Android::VersionHelper.get_release_version(product_name: app)
|
10
|
+
current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
13
11
|
new_version = Fastlane::Helper::Android::VersionHelper.calc_next_hotfix_version(params[:version_name], params[:version_code]) # NOTE: this just puts the name/code values in a tuple, unchanged (no actual calc/bumping)
|
14
12
|
new_release_branch = "release/#{params[:version_name]}"
|
15
13
|
|
16
14
|
name_key = Fastlane::Helper::Android::VersionHelper::VERSION_NAME
|
17
15
|
code_key = Fastlane::Helper::Android::VersionHelper::VERSION_CODE
|
18
|
-
UI.message("Current version
|
19
|
-
UI.message("New hotfix version
|
16
|
+
UI.message("Current version: #{current_version[name_key]} (#{current_version[code_key]})")
|
17
|
+
UI.message("New hotfix version: #{new_version[name_key]} (#{new_version[code_key]})")
|
20
18
|
UI.message("Release branch: #{new_release_branch}")
|
21
19
|
|
22
20
|
UI.message 'Updating app version...'
|
23
|
-
Fastlane::Helper::Android::VersionHelper.update_versions(
|
21
|
+
Fastlane::Helper::Android::VersionHelper.update_versions(new_version, nil)
|
24
22
|
UI.message 'Done!'
|
25
23
|
|
26
24
|
Fastlane::Helper::Android::GitHelper.commit_version_bump()
|
@@ -33,11 +31,11 @@ module Fastlane
|
|
33
31
|
#####################################################
|
34
32
|
|
35
33
|
def self.description
|
36
|
-
'Bumps the version of the app for a new beta.
|
34
|
+
'Bumps the version of the app for a new beta.'
|
37
35
|
end
|
38
36
|
|
39
37
|
def self.details
|
40
|
-
'Bumps the version of the app for a new beta.
|
38
|
+
'Bumps the version of the app for a new beta.'
|
41
39
|
end
|
42
40
|
|
43
41
|
def self.available_options
|
@@ -53,10 +51,6 @@ module Fastlane
|
|
53
51
|
env_name: 'FL_ANDROID_BUMP_VERSION_HOTFIX_PREVIOUS_VERSION',
|
54
52
|
description: 'The version to branch from',
|
55
53
|
is_string: true),
|
56
|
-
FastlaneCore::ConfigItem.new(key: :app,
|
57
|
-
env_name: 'PROJECT_NAME',
|
58
|
-
description: 'The name of the app to get the release version for',
|
59
|
-
is_string: true),
|
60
54
|
]
|
61
55
|
end
|
62
56
|
|
@@ -8,34 +8,34 @@ module Fastlane
|
|
8
8
|
require_relative '../../helper/android/android_version_helper'
|
9
9
|
require_relative '../../helper/android/android_git_helper'
|
10
10
|
|
11
|
-
|
11
|
+
default_branch = params[:default_branch]
|
12
|
+
other_action.ensure_git_branch(branch: default_branch)
|
12
13
|
|
13
14
|
# Create new configuration
|
14
|
-
|
15
|
-
new_short_version = Fastlane::Helper::Android::VersionHelper.bump_version_release(app)
|
15
|
+
new_short_version = Fastlane::Helper::Android::VersionHelper.bump_version_release
|
16
16
|
|
17
|
-
current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
18
|
-
current_version_alpha = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
17
|
+
current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
18
|
+
current_version_alpha = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
19
19
|
new_version_beta = Fastlane::Helper::Android::VersionHelper.calc_next_release_version(current_version, current_version_alpha)
|
20
20
|
new_version_alpha = current_version_alpha.nil? ? nil : Fastlane::Helper::Android::VersionHelper.calc_next_alpha_version(new_version_beta, current_version_alpha)
|
21
21
|
new_release_branch = "release/#{new_short_version}"
|
22
22
|
|
23
23
|
vname = Fastlane::Helper::Android::VersionHelper::VERSION_NAME
|
24
24
|
vcode = Fastlane::Helper::Android::VersionHelper::VERSION_CODE
|
25
|
-
UI.message("Current version
|
26
|
-
UI.message("Current alpha version
|
27
|
-
UI.message("New beta version
|
28
|
-
UI.message("New alpha version
|
29
|
-
UI.message("New version
|
25
|
+
UI.message("Current version: #{current_version[vname]}(#{current_version[vcode]})")
|
26
|
+
UI.message("Current alpha version: #{current_version_alpha[vname]}(#{current_version_alpha[vcode]})") unless current_version_alpha.nil?
|
27
|
+
UI.message("New beta version: #{new_version_beta[vname]}(#{new_version_beta[vcode]})")
|
28
|
+
UI.message("New alpha version: #{new_version_alpha[vname]}(#{new_version_alpha[vcode]})") unless current_version_alpha.nil?
|
29
|
+
UI.message("New version: #{new_short_version}")
|
30
30
|
UI.message("Release branch: #{new_release_branch}")
|
31
31
|
|
32
|
-
# Update local
|
32
|
+
# Update local default branch and create branch from it
|
33
33
|
UI.message 'Creating new branch...'
|
34
|
-
Fastlane::Helper::GitHelper.create_branch(new_release_branch, from:
|
34
|
+
Fastlane::Helper::GitHelper.create_branch(new_release_branch, from: default_branch)
|
35
35
|
UI.message 'Done!'
|
36
36
|
|
37
37
|
UI.message 'Updating app version...'
|
38
|
-
Fastlane::Helper::Android::VersionHelper.update_versions(
|
38
|
+
Fastlane::Helper::Android::VersionHelper.update_versions(new_version_beta, new_version_alpha)
|
39
39
|
Fastlane::Helper::Android::GitHelper.commit_version_bump()
|
40
40
|
UI.message 'Done.'
|
41
41
|
end
|
@@ -45,20 +45,20 @@ module Fastlane
|
|
45
45
|
#####################################################
|
46
46
|
|
47
47
|
def self.description
|
48
|
-
'Bumps the version of the app for a new beta.
|
48
|
+
'Bumps the version of the app for a new beta.'
|
49
49
|
end
|
50
50
|
|
51
51
|
def self.details
|
52
|
-
'Bumps the version of the app for a new beta.
|
52
|
+
'Bumps the version of the app for a new beta.'
|
53
53
|
end
|
54
54
|
|
55
55
|
def self.available_options
|
56
|
-
# Define all options your action supports.
|
57
56
|
[
|
58
|
-
FastlaneCore::ConfigItem.new(key: :
|
59
|
-
env_name: '
|
60
|
-
description: '
|
61
|
-
|
57
|
+
FastlaneCore::ConfigItem.new(key: :default_branch,
|
58
|
+
env_name: 'FL_RELEASE_TOOLKIT_DEFAULT_BRANCH',
|
59
|
+
description: 'Default branch of the repository',
|
60
|
+
type: String,
|
61
|
+
default_value: Fastlane::Helper::GitHelper::DEFAULT_GIT_BRANCH),
|
62
62
|
]
|
63
63
|
end
|
64
64
|
|
@@ -11,21 +11,20 @@ module Fastlane
|
|
11
11
|
require_relative '../../helper/android/android_version_helper'
|
12
12
|
require_relative '../../helper/android/android_git_helper'
|
13
13
|
|
14
|
-
# Checkout
|
15
|
-
|
16
|
-
|
17
|
-
app = params[:app]
|
14
|
+
# Checkout default branch and update
|
15
|
+
default_branch = params[:default_branch]
|
16
|
+
Fastlane::Helper::GitHelper.checkout_and_pull(default_branch)
|
18
17
|
|
19
18
|
# Create versions
|
20
|
-
current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
21
|
-
current_alpha_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
19
|
+
current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
20
|
+
current_alpha_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
22
21
|
next_version = Fastlane::Helper::Android::VersionHelper.calc_next_release_version(current_version, current_alpha_version)
|
23
22
|
next_alpha_version = current_alpha_version.nil? ? nil : Fastlane::Helper::Android::VersionHelper.calc_next_alpha_version(next_version, current_alpha_version)
|
24
23
|
|
25
24
|
no_alpha_version_message = "No alpha version configured. If you wish to configure an alpha version please update version.properties to include an alpha key for this app\n"
|
26
25
|
# Ask user confirmation
|
27
26
|
unless params[:skip_confirm]
|
28
|
-
confirm_message = "
|
27
|
+
confirm_message = "Building a new release branch starting from #{default_branch}.\nCurrent version is #{current_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]} (#{current_version[Fastlane::Helper::Android::VersionHelper::VERSION_CODE]}).\n"
|
29
28
|
confirm_message += current_alpha_version.nil? ? no_alpha_version_message : "Current Alpha version is #{current_alpha_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]} (#{current_alpha_version[Fastlane::Helper::Android::VersionHelper::VERSION_CODE]}).\n"
|
30
29
|
confirm_message += "After codefreeze the new version will be: #{next_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]} (#{next_version[Fastlane::Helper::Android::VersionHelper::VERSION_CODE]}).\n"
|
31
30
|
confirm_message += current_alpha_version.nil? ? '' : "After codefreeze the new Alpha will be: #{next_alpha_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]} (#{next_alpha_version[Fastlane::Helper::Android::VersionHelper::VERSION_CODE]}).\n"
|
@@ -37,7 +36,7 @@ module Fastlane
|
|
37
36
|
other_action.ensure_git_status_clean()
|
38
37
|
|
39
38
|
# Return the current version
|
40
|
-
Fastlane::Helper::Android::VersionHelper.get_public_version
|
39
|
+
Fastlane::Helper::Android::VersionHelper.get_public_version
|
41
40
|
end
|
42
41
|
|
43
42
|
#####################################################
|
@@ -49,7 +48,7 @@ module Fastlane
|
|
49
48
|
end
|
50
49
|
|
51
50
|
def self.details
|
52
|
-
'Updates the
|
51
|
+
'Updates the default branch, checks the app version and ensure the branch is clean'
|
53
52
|
end
|
54
53
|
|
55
54
|
def self.available_options
|
@@ -60,10 +59,11 @@ module Fastlane
|
|
60
59
|
description: 'Skips confirmation before codefreeze',
|
61
60
|
is_string: false, # true: verifies the input is a string, false: every kind of value
|
62
61
|
default_value: false), # the default value if the user didn't provide one
|
63
|
-
FastlaneCore::ConfigItem.new(key: :
|
64
|
-
env_name: '
|
65
|
-
description: '
|
66
|
-
|
62
|
+
FastlaneCore::ConfigItem.new(key: :default_branch,
|
63
|
+
env_name: 'FL_RELEASE_TOOLKIT_DEFAULT_BRANCH',
|
64
|
+
description: 'Default branch of the repository',
|
65
|
+
type: String,
|
66
|
+
default_value: Fastlane::Helper::GitHelper::DEFAULT_GIT_BRANCH),
|
67
67
|
]
|
68
68
|
end
|
69
69
|
|
data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_completecodefreeze_prechecks.rb
CHANGED
@@ -9,10 +9,8 @@ module Fastlane
|
|
9
9
|
|
10
10
|
UI.user_error!('This is not a release branch. Abort.') unless other_action.git_branch.start_with?('release/')
|
11
11
|
|
12
|
-
|
13
|
-
|
14
|
-
version = Fastlane::Helper::Android::VersionHelper.get_public_version(app)
|
15
|
-
message = "Completing code freeze for: [#{app}]#{version}\n"
|
12
|
+
version = Fastlane::Helper::Android::VersionHelper.get_public_version
|
13
|
+
message = "Completing code freeze for: #{version}\n"
|
16
14
|
unless params[:skip_confirm]
|
17
15
|
UI.user_error!('Aborted by user request') unless UI.confirm("#{message}Do you want to continue?")
|
18
16
|
else
|
@@ -44,10 +42,6 @@ module Fastlane
|
|
44
42
|
description: 'Skips confirmation',
|
45
43
|
is_string: false, # true: verifies the input is a string, false: every kind of value
|
46
44
|
default_value: false), # the default value if the user didn't provide one
|
47
|
-
FastlaneCore::ConfigItem.new(key: :app,
|
48
|
-
env_name: 'PROJECT_NAME',
|
49
|
-
description: 'The name of the app to get the release version for',
|
50
|
-
is_string: true), # true: verifies the input is a string, false: every kind of value
|
51
45
|
]
|
52
46
|
end
|
53
47
|
|
data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_current_branch_is_hotfix.rb
CHANGED
@@ -7,7 +7,7 @@ module Fastlane
|
|
7
7
|
class AndroidCurrentBranchIsHotfixAction < Action
|
8
8
|
def self.run(params)
|
9
9
|
require_relative '../../helper/android/android_version_helper'
|
10
|
-
version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
10
|
+
version = Fastlane::Helper::Android::VersionHelper.get_release_version
|
11
11
|
Fastlane::Helper::Android::VersionHelper.is_hotfix?(version)
|
12
12
|
end
|
13
13
|
|
@@ -25,12 +25,6 @@ module Fastlane
|
|
25
25
|
|
26
26
|
def self.available_options
|
27
27
|
# Define all options your action supports.
|
28
|
-
[
|
29
|
-
FastlaneCore::ConfigItem.new(key: :app,
|
30
|
-
env_name: 'PROJECT_NAME',
|
31
|
-
description: 'The name of the app to get the release version for',
|
32
|
-
is_string: true), # true: verifies the input is a string, false: every kind of value
|
33
|
-
]
|
34
28
|
end
|
35
29
|
|
36
30
|
def self.output
|
data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_download_file_by_version.rb
CHANGED
@@ -27,7 +27,7 @@ module Fastlane
|
|
27
27
|
|
28
28
|
def self.details
|
29
29
|
'This action extracts the version of the library which is imported by the client app' \
|
30
|
-
|
30
|
+
'and downloads the request file from the relevant GitHub release'
|
31
31
|
end
|
32
32
|
|
33
33
|
def self.available_options
|
@@ -13,8 +13,8 @@ module Fastlane
|
|
13
13
|
|
14
14
|
UI.user_error!('This is not a release branch. Abort.') unless other_action.git_branch.start_with?('release/')
|
15
15
|
|
16
|
-
version = Fastlane::Helper::Android::VersionHelper.get_public_version
|
17
|
-
message = "Finalizing
|
16
|
+
version = Fastlane::Helper::Android::VersionHelper.get_public_version
|
17
|
+
message = "Finalizing release: #{version}\n"
|
18
18
|
if params[:skip_confirm]
|
19
19
|
UI.message(message)
|
20
20
|
else
|
@@ -49,10 +49,6 @@ module Fastlane
|
|
49
49
|
description: 'Skips confirmation',
|
50
50
|
is_string: false, # true: verifies the input is a string, false: every kind of value
|
51
51
|
default_value: false), # the default value if the user didn't provide one
|
52
|
-
FastlaneCore::ConfigItem.new(key: :app,
|
53
|
-
env_name: 'PROJECT_NAME',
|
54
|
-
description: 'The name of the app to get the release version for',
|
55
|
-
is_string: true), # true: verifies the input is a string, false: every kind of value
|
56
52
|
]
|
57
53
|
end
|
58
54
|
|
@@ -3,7 +3,7 @@ module Fastlane
|
|
3
3
|
class AndroidGetAlphaVersionAction < Action
|
4
4
|
def self.run(params)
|
5
5
|
require_relative '../../helper/android/android_version_helper'
|
6
|
-
Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
6
|
+
Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
7
7
|
end
|
8
8
|
|
9
9
|
#####################################################
|
@@ -20,12 +20,6 @@ module Fastlane
|
|
20
20
|
|
21
21
|
def self.available_options
|
22
22
|
# Define all options your action supports.
|
23
|
-
[
|
24
|
-
FastlaneCore::ConfigItem.new(key: :app,
|
25
|
-
env_name: 'PROJECT_NAME',
|
26
|
-
description: 'The name of the app to get the release version for',
|
27
|
-
is_string: true), # true: verifies the input is a string, false: every kind of value
|
28
|
-
]
|
29
23
|
end
|
30
24
|
|
31
25
|
def self.output
|
@@ -3,7 +3,7 @@ module Fastlane
|
|
3
3
|
class AndroidGetAppVersionAction < Action
|
4
4
|
def self.run(params)
|
5
5
|
require_relative '../../helper/android/android_version_helper'
|
6
|
-
Fastlane::Helper::Android::VersionHelper.get_public_version
|
6
|
+
Fastlane::Helper::Android::VersionHelper.get_public_version
|
7
7
|
end
|
8
8
|
|
9
9
|
#####################################################
|
@@ -20,12 +20,6 @@ module Fastlane
|
|
20
20
|
|
21
21
|
def self.available_options
|
22
22
|
# Define all options your action supports.
|
23
|
-
[
|
24
|
-
FastlaneCore::ConfigItem.new(key: :app,
|
25
|
-
env_name: 'PROJECT_NAME',
|
26
|
-
description: 'The name of the app to get the release version for',
|
27
|
-
is_string: true), # true: verifies the input is a string, false: every kind of value
|
28
|
-
]
|
29
23
|
end
|
30
24
|
|
31
25
|
def self.output
|
@@ -3,7 +3,7 @@ module Fastlane
|
|
3
3
|
class AndroidGetReleaseVersionAction < Action
|
4
4
|
def self.run(params)
|
5
5
|
require_relative '../../helper/android/android_version_helper'
|
6
|
-
Fastlane::Helper::Android::VersionHelper.get_release_version
|
6
|
+
Fastlane::Helper::Android::VersionHelper.get_release_version
|
7
7
|
end
|
8
8
|
|
9
9
|
#####################################################
|
@@ -20,12 +20,6 @@ module Fastlane
|
|
20
20
|
|
21
21
|
def self.available_options
|
22
22
|
# Define all options your action supports.
|
23
|
-
[
|
24
|
-
FastlaneCore::ConfigItem.new(key: :app,
|
25
|
-
env_name: 'PROJECT_NAME',
|
26
|
-
description: 'The name of the app to get the release version for',
|
27
|
-
is_string: true), # true: verifies the input is a string, false: every kind of value
|
28
|
-
]
|
29
23
|
end
|
30
24
|
|
31
25
|
def self.output
|
@@ -5,10 +5,8 @@ module Fastlane
|
|
5
5
|
require_relative '../../helper/android/android_version_helper'
|
6
6
|
require_relative '../../helper/android/android_git_helper'
|
7
7
|
|
8
|
-
|
9
|
-
|
10
|
-
release_ver = Fastlane::Helper::Android::VersionHelper.get_release_version(product_name: app)
|
11
|
-
alpha_ver = Fastlane::Helper::Android::VersionHelper.get_alpha_version(app)
|
8
|
+
release_ver = Fastlane::Helper::Android::VersionHelper.get_release_version
|
9
|
+
alpha_ver = Fastlane::Helper::Android::VersionHelper.get_alpha_version
|
12
10
|
Fastlane::Helper::GitHelper.create_tag(release_ver[Fastlane::Helper::Android::VersionHelper::VERSION_NAME])
|
13
11
|
Fastlane::Helper::GitHelper.create_tag(alpha_ver[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]) unless alpha_ver.nil? || (params[:tag_alpha] == false)
|
14
12
|
end
|
@@ -32,10 +30,6 @@ module Fastlane
|
|
32
30
|
description: 'True to skip tagging the alpha version',
|
33
31
|
is_string: false,
|
34
32
|
default_value: true),
|
35
|
-
FastlaneCore::ConfigItem.new(key: :app,
|
36
|
-
env_name: 'PROJECT_NAME',
|
37
|
-
description: 'The name of the app to get the release version for',
|
38
|
-
is_string: true), # true: verifies the input is a string, false: every kind of value
|
39
33
|
]
|
40
34
|
end
|
41
35
|
|
@@ -98,7 +98,7 @@ module Fastlane
|
|
98
98
|
|
99
99
|
def self.details
|
100
100
|
'This actions checks the current status of the translations on GlotPress ' \
|
101
|
-
|
101
|
+
'and raises an error if it\'s below the provided threshold'
|
102
102
|
end
|
103
103
|
|
104
104
|
def self.available_options
|