fastlane-plugin-wpmreleasetoolkit 1.3.1 → 2.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (31) hide show
  1. checksums.yaml +4 -4
  2. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_betabuild_prechecks.rb +11 -17
  3. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_build_prechecks.rb +5 -10
  4. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_bump_version_beta.rb +9 -16
  5. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_bump_version_final_release.rb +8 -15
  6. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_bump_version_hotfix.rb +13 -22
  7. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_bump_version_release.rb +11 -18
  8. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_codefreeze_prechecks.rb +4 -10
  9. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_completecodefreeze_prechecks.rb +2 -8
  10. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_current_branch_is_hotfix.rb +1 -7
  11. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_download_file_by_version.rb +1 -1
  12. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_finalize_prechecks.rb +2 -6
  13. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_get_alpha_version.rb +1 -7
  14. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_get_app_version.rb +1 -7
  15. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_get_release_version.rb +1 -7
  16. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_hotifx_prechecks.rb +4 -4
  17. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/android/android_tag_build.rb +2 -8
  18. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/common/check_translation_progress.rb +1 -1
  19. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/common/comment_on_pr.rb +89 -0
  20. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/common/create_release_action.rb +3 -1
  21. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_bump_version_hotfix.rb +30 -15
  22. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_generate_strings_file_from_code.rb +115 -0
  23. data/lib/fastlane/plugin/wpmreleasetoolkit/actions/ios/ios_localize_project.rb +5 -6
  24. data/lib/fastlane/plugin/wpmreleasetoolkit/helper/an_metadata_update_helper.rb +1 -1
  25. data/lib/fastlane/plugin/wpmreleasetoolkit/helper/android/android_git_helper.rb +1 -1
  26. data/lib/fastlane/plugin/wpmreleasetoolkit/helper/android/android_version_helper.rb +33 -68
  27. data/lib/fastlane/plugin/wpmreleasetoolkit/helper/filesystem_helper.rb +3 -1
  28. data/lib/fastlane/plugin/wpmreleasetoolkit/helper/github_helper.rb +48 -8
  29. data/lib/fastlane/plugin/wpmreleasetoolkit/helper/interactive_prompt_reminder.rb +93 -0
  30. data/lib/fastlane/plugin/wpmreleasetoolkit/version.rb +1 -1
  31. metadata +27 -4
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b71ab5451b2a1bee74b6dd874e20e478d03501fe4ed86124bb4f4d0ffe6a07eb
4
- data.tar.gz: c2cd6dd78f92ac8ff85d54f0f778461213eab8aa748a0654290385bc99989544
3
+ metadata.gz: a118f64ccb017604c68c8f62c56b91d4bea3ec92f26e2942ec28caf681a811a7
4
+ data.tar.gz: 4c09125195256749d839aac630c4393fab86f08363304b70b6e3d452c8aae96a
5
5
  SHA512:
6
- metadata.gz: eb16735f4f4f54835ce9873cd11f7f62f04f6dfd194474ab78c5f5e6408281306367c90cb85fcc036bb6845a1ace13241cba07af56ded24d8fb50ed8d3debf17
7
- data.tar.gz: 38fa14c33229c990a6e1f42062d644da704d89af6fd7dae2be5d3d2f749de684747f7ce56f976fad7514fc4940253ff66aec94ff09498e6a3eaf82f5f9aa49f6
6
+ metadata.gz: '04158059883cdf0a9f19077a616020fe027fc25a574d8e84605ca40d948763a33dd7373dbc526a26bc0e99f3fab4c20b38e2f10799bc2dd9bd953437fe6b7fb5'
7
+ data.tar.gz: 741ea4ad0ba1b022bd856839d72c4a4847cfc0d5377c350fea687e85b685bca3cb95206e5ae6999f2c1792938966578376e58d8810cd719fc5cbf2e8c866ebcb
@@ -11,21 +11,19 @@ module Fastlane
11
11
  # Checkout develop and update
12
12
  Fastlane::Helper::GitHelper.checkout_and_pull('develop')
13
13
 
14
- app = params[:app]
15
-
16
14
  # Check versions
17
- release_version = Fastlane::Helper::Android::VersionHelper.get_release_version(product_name: app)
18
- message = "[#{app}] The following current version has been detected: #{release_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}\n"
19
- alpha_release_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version(app)
20
- message << "[#{app}] The following Alpha version has been detected: #{alpha_release_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}\n" unless alpha_release_version.nil?
15
+ release_version = Fastlane::Helper::Android::VersionHelper.get_release_version
16
+ message = "The following current version has been detected: #{release_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}\n"
17
+ alpha_release_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version
18
+ message << "The following Alpha version has been detected: #{alpha_release_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}\n" unless alpha_release_version.nil?
21
19
 
22
20
  # Check branch
23
- app_version = Fastlane::Helper::Android::VersionHelper.get_public_version(app)
21
+ app_version = Fastlane::Helper::Android::VersionHelper.get_public_version
24
22
  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
23
 
26
24
  # Check user overwrite
27
25
  unless params[:base_version].nil?
28
- overwrite_version = get_user_build_version(product_name: app, version: params[:base_version], message: message)
26
+ overwrite_version = get_user_build_version(version: params[:base_version], message: message)
29
27
  release_version = overwrite_version[0]
30
28
  alpha_release_version = overwrite_version[1]
31
29
  end
@@ -49,11 +47,11 @@ module Fastlane
49
47
  [next_beta_version, next_alpha_version]
50
48
  end
51
49
 
52
- def self.get_user_build_version(product_name:, version:, message:)
53
- UI.user_error!("[#{app}] Release branch for version #{version} doesn't exist. Abort.") unless Fastlane::Helper::GitHelper.checkout_and_pull(release: version)
54
- release_version = Fastlane::Helper::Android::VersionHelper.get_release_version(product_name: product_name)
55
- message << "#{app}] Looking at branch release/#{version} as requested by user. Detected version: #{release_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}.\n"
56
- alpha_release_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version(product_name)
50
+ def self.get_user_build_version(version:, message:)
51
+ UI.user_error!("Release branch for version #{version} doesn't exist. Abort.") unless Fastlane::Helper::GitHelper.checkout_and_pull(release: version)
52
+ release_version = Fastlane::Helper::Android::VersionHelper.get_release_version
53
+ message << "Looking at branch release/#{version} as requested by user. Detected version: #{release_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}.\n"
54
+ alpha_release_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version
57
55
  message << "and Alpha Version: #{alpha_release_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}\n" unless alpha_release_version.nil?
58
56
  [release_version, alpha_release_version]
59
57
  end
@@ -82,10 +80,6 @@ module Fastlane
82
80
  description: 'Skips confirmation',
83
81
  is_string: false, # true: verifies the input is a string, false: every kind of value
84
82
  default_value: false), # the default value if the user didn't provide one
85
- FastlaneCore::ConfigItem.new(key: :app,
86
- env_name: 'PROJECT_NAME',
87
- description: 'The name of the app to get the release version for',
88
- is_string: true), # true: verifies the input is a string, false: every kind of value
89
83
  ]
90
84
  end
91
85
 
@@ -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(product_name: app) unless !params[:beta] && !params[:final]
15
- alpha_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version(app) if params[:alpha]
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 << "[#{app}] 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]
20
- message << "[#{app}] 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]
21
- message << "[#{app}] 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]
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(product_name: app)
14
- current_version_alpha = Fastlane::Helper::Android::VersionHelper.get_alpha_version(app)
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[#{app}]: #{current_version[vname]}(#{current_version[vcode]})")
21
- UI.message("Current alpha version[#{app}]: #{current_version_alpha[vname]}(#{current_version_alpha[vcode]})") unless current_version_alpha.nil?
22
- UI.message("New beta version[#{app}]: #{new_version_beta[vname]}(#{new_version_beta[vcode]})")
23
- UI.message("New alpha version[#{app}]: #{new_version_alpha[vname]}(#{new_version_alpha[vcode]})") unless current_version_alpha.nil?
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(app, new_version_beta, new_version_alpha)
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. Requires the `updateVersionProperties` gradle task to update the keys if you are using a `version.properties` file.'
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. Requires the `updateVersionProperties` gradle task to update the keys if you are using a `version.properties` file.'
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
@@ -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(product_name: app)
14
- current_version_alpha = Fastlane::Helper::Android::VersionHelper.get_alpha_version(app)
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[#{app}]: #{current_version[vname]}(#{current_version[vcode]})")
20
- UI.message("Current alpha version[#{app}]: #{current_version_alpha[vname]}(#{current_version_alpha[vcode]})") unless current_version_alpha.nil?
21
- UI.message("New release version[#{app}]: #{final_version[vname]}(#{final_version[vcode]})")
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(app, final_version, current_version_alpha)
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. Requires the `updateVersionProperties` gradle task to update the keys if you are using a `version.properties` file.'
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. Requires the `updateVersionProperties` gradle task to update the keys if you are using a `version.properties` file.'
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
- app = params[:app]
10
+ current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
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)
12
+ new_release_branch = "release/#{params[:version_name]}"
11
13
 
12
- current_version = Fastlane::Helper::Android::VersionHelper.get_release_version(product_name: app)
13
- current_version_alpha = Fastlane::Helper::Android::VersionHelper.get_alpha_version(app)
14
- new_version = Fastlane::Helper::Android::VersionHelper.calc_next_hotfix_version(params[:version_name], params[:version_code])
15
- new_short_version = new_version_name
16
- new_release_branch = "release/#{new_short_version}"
17
-
18
- UI.message("Current version[#{app}]: #{current_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}(#{current_version[Fastlane::Helper::Android::VersionHelper::VERSION_CODE]})")
19
- UI.message("New hotfix version[#{app}]: #{new_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]}(#{new_version[Fastlane::Helper::Android::VersionHelper::VERSION_CODE]})")
14
+ name_key = Fastlane::Helper::Android::VersionHelper::VERSION_NAME
15
+ code_key = Fastlane::Helper::Android::VersionHelper::VERSION_CODE
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(app, new_version, current_version_alpha)
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,33 +31,26 @@ module Fastlane
33
31
  #####################################################
34
32
 
35
33
  def self.description
36
- 'Bumps the version of the app for a new beta. Requires the `updateVersionProperties` gradle task to update the keys if you are using a `version.properties` file.'
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. Requires the `updateVersionProperties` gradle task to update the keys if you are using a `version.properties` file.'
38
+ 'Bumps the version of the app for a new beta.'
41
39
  end
42
40
 
43
41
  def self.available_options
44
- # Define all options your action supports.
45
-
46
- # Below a few examples
47
42
  [
48
43
  FastlaneCore::ConfigItem.new(key: :version_name,
49
44
  env_name: 'FL_ANDROID_BUMP_VERSION_HOTFIX_VERSION',
50
- description: 'The version of the hotfix',
45
+ description: 'The version name for the hotfix',
51
46
  is_string: true),
52
47
  FastlaneCore::ConfigItem.new(key: :version_code,
53
48
  env_name: 'FL_ANDROID_BUMP_VERSION_HOTFIX_CODE',
54
- description: 'The version of the hotfix'),
49
+ description: 'The version code for the hotfix'),
55
50
  FastlaneCore::ConfigItem.new(key: :previous_version_name,
56
51
  env_name: 'FL_ANDROID_BUMP_VERSION_HOTFIX_PREVIOUS_VERSION',
57
52
  description: 'The version to branch from',
58
- is_string: true), # the default value if the user didn't provide one
59
- FastlaneCore::ConfigItem.new(key: :app,
60
- env_name: 'PROJECT_NAME',
61
- description: 'The name of the app to get the release version for',
62
- is_string: true), # true: verifies the input is a string, false: every kind of value
53
+ is_string: true),
63
54
  ]
64
55
  end
65
56
 
@@ -11,22 +11,21 @@ module Fastlane
11
11
  other_action.ensure_git_branch(branch: 'develop')
12
12
 
13
13
  # Create new configuration
14
- app = params[:app]
15
- new_short_version = Fastlane::Helper::Android::VersionHelper.bump_version_release(app)
14
+ new_short_version = Fastlane::Helper::Android::VersionHelper.bump_version_release
16
15
 
17
- current_version = Fastlane::Helper::Android::VersionHelper.get_release_version(product_name: app)
18
- current_version_alpha = Fastlane::Helper::Android::VersionHelper.get_alpha_version(app)
16
+ current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
17
+ current_version_alpha = Fastlane::Helper::Android::VersionHelper.get_alpha_version
19
18
  new_version_beta = Fastlane::Helper::Android::VersionHelper.calc_next_release_version(current_version, current_version_alpha)
20
19
  new_version_alpha = current_version_alpha.nil? ? nil : Fastlane::Helper::Android::VersionHelper.calc_next_alpha_version(new_version_beta, current_version_alpha)
21
20
  new_release_branch = "release/#{new_short_version}"
22
21
 
23
22
  vname = Fastlane::Helper::Android::VersionHelper::VERSION_NAME
24
23
  vcode = Fastlane::Helper::Android::VersionHelper::VERSION_CODE
25
- UI.message("Current version[#{app}]: #{current_version[vname]}(#{current_version[vcode]})")
26
- UI.message("Current alpha version[#{app}]: #{current_version_alpha[vname]}(#{current_version_alpha[vcode]})") unless current_version_alpha.nil?
27
- UI.message("New beta version[#{app}]: #{new_version_beta[vname]}(#{new_version_beta[vcode]})")
28
- UI.message("New alpha version[#{app}]: #{new_version_alpha[vname]}(#{new_version_alpha[vcode]})") unless current_version_alpha.nil?
29
- UI.message("New version[#{app}]: #{new_short_version}")
24
+ UI.message("Current version: #{current_version[vname]}(#{current_version[vcode]})")
25
+ UI.message("Current alpha version: #{current_version_alpha[vname]}(#{current_version_alpha[vcode]})") unless current_version_alpha.nil?
26
+ UI.message("New beta version: #{new_version_beta[vname]}(#{new_version_beta[vcode]})")
27
+ UI.message("New alpha version: #{new_version_alpha[vname]}(#{new_version_alpha[vcode]})") unless current_version_alpha.nil?
28
+ UI.message("New version: #{new_short_version}")
30
29
  UI.message("Release branch: #{new_release_branch}")
31
30
 
32
31
  # Update local develop and branch
@@ -35,7 +34,7 @@ module Fastlane
35
34
  UI.message 'Done!'
36
35
 
37
36
  UI.message 'Updating app version...'
38
- Fastlane::Helper::Android::VersionHelper.update_versions(app, new_version_beta, new_version_alpha)
37
+ Fastlane::Helper::Android::VersionHelper.update_versions(new_version_beta, new_version_alpha)
39
38
  Fastlane::Helper::Android::GitHelper.commit_version_bump()
40
39
  UI.message 'Done.'
41
40
  end
@@ -45,21 +44,15 @@ module Fastlane
45
44
  #####################################################
46
45
 
47
46
  def self.description
48
- 'Bumps the version of the app for a new beta. Requires the `updateVersionProperties` gradle task to update the keys if you are using a `version.properties` file.'
47
+ 'Bumps the version of the app for a new beta.'
49
48
  end
50
49
 
51
50
  def self.details
52
- 'Bumps the version of the app for a new beta. Requires the `updateVersionProperties` gradle task to update the keys if you are using a `version.properties` file.'
51
+ 'Bumps the version of the app for a new beta.'
53
52
  end
54
53
 
55
54
  def self.available_options
56
55
  # Define all options your action supports.
57
- [
58
- FastlaneCore::ConfigItem.new(key: :app,
59
- env_name: 'PROJECT_NAME',
60
- description: 'The name of the app to get the release version for',
61
- is_string: true), # true: verifies the input is a string, false: every kind of value
62
- ]
63
56
  end
64
57
 
65
58
  def self.output
@@ -14,18 +14,16 @@ module Fastlane
14
14
  # Checkout develop and update
15
15
  Fastlane::Helper::GitHelper.checkout_and_pull('develop')
16
16
 
17
- app = params[:app]
18
-
19
17
  # Create versions
20
- current_version = Fastlane::Helper::Android::VersionHelper.get_release_version(product_name: app)
21
- current_alpha_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version(app)
18
+ current_version = Fastlane::Helper::Android::VersionHelper.get_release_version
19
+ current_alpha_version = Fastlane::Helper::Android::VersionHelper.get_alpha_version
22
20
  next_version = Fastlane::Helper::Android::VersionHelper.calc_next_release_version(current_version, current_alpha_version)
23
21
  next_alpha_version = current_alpha_version.nil? ? nil : Fastlane::Helper::Android::VersionHelper.calc_next_alpha_version(next_version, current_alpha_version)
24
22
 
25
23
  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
24
  # Ask user confirmation
27
25
  unless params[:skip_confirm]
28
- confirm_message = "[#{app}]Building a new release branch starting from develop.\nCurrent version is #{current_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]} (#{current_version[Fastlane::Helper::Android::VersionHelper::VERSION_CODE]}).\n"
26
+ confirm_message = "Building a new release branch starting from develop.\nCurrent version is #{current_version[Fastlane::Helper::Android::VersionHelper::VERSION_NAME]} (#{current_version[Fastlane::Helper::Android::VersionHelper::VERSION_CODE]}).\n"
29
27
  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
28
  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
29
  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 +35,7 @@ module Fastlane
37
35
  other_action.ensure_git_status_clean()
38
36
 
39
37
  # Return the current version
40
- Fastlane::Helper::Android::VersionHelper.get_public_version(app)
38
+ Fastlane::Helper::Android::VersionHelper.get_public_version
41
39
  end
42
40
 
43
41
  #####################################################
@@ -60,10 +58,6 @@ module Fastlane
60
58
  description: 'Skips confirmation before codefreeze',
61
59
  is_string: false, # true: verifies the input is a string, false: every kind of value
62
60
  default_value: false), # the default value if the user didn't provide one
63
- FastlaneCore::ConfigItem.new(key: :app,
64
- env_name: 'PROJECT_NAME',
65
- description: 'The name of the app to get the release version for',
66
- is_string: true), # true: verifies the input is a string, false: every kind of value
67
61
  ]
68
62
  end
69
63
 
@@ -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
- app = params[:app]
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
 
@@ -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(product_name: params[:app])
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
@@ -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
- 'and downloads the request file from the relevant GitHub release'
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(params[:app])
17
- message = "Finalizing #{params[:app]} release: #{version}\n"
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(params[:app])
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(params[:app])
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(product_name: params[:app])
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
@@ -14,7 +14,7 @@ module Fastlane
14
14
 
15
15
  # Confirm
16
16
  message = "Requested Hotfix version: #{new_ver}\n"
17
- message << "Branching from: #{prev_ver}\n"
17
+ message << "Branching from tag: #{prev_ver}\n"
18
18
 
19
19
  if params[:skip_confirm]
20
20
  UI.message(message)
@@ -50,13 +50,13 @@ module Fastlane
50
50
  [
51
51
  FastlaneCore::ConfigItem.new(key: :version_name,
52
52
  env_name: 'FL_ANDROID_HOTFIX_PRECHECKS_VERSION',
53
- description: 'The version to work on', # a short description of this parameter
53
+ description: 'The hotfix version number to create',
54
54
  is_string: true),
55
55
  FastlaneCore::ConfigItem.new(key: :skip_confirm,
56
56
  env_name: 'FL_ANDROID_HOTFIX_PRECHECKS_SKIPCONFIRM',
57
57
  description: 'Skips confirmation',
58
- is_string: false, # true: verifies the input is a string, false: every kind of value
59
- default_value: false), # the default value if the user didn't provide one
58
+ is_string: false, # Boolean
59
+ default_value: false),
60
60
  ]
61
61
  end
62
62
 
@@ -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
- app = ENV['PROJECT_NAME'].nil? ? params[:app] : ENV['PROJECT_NAME']
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
- 'and raises an error if it\'s below the provided threshold'
101
+ 'and raises an error if it\'s below the provided threshold'
102
102
  end
103
103
 
104
104
  def self.available_options