fastlane-plugin-auto_version_name 0.2.1 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8f10a1f69013f98b7eed2528d10c4752aebbb4f4e724d49d89f0f8f9ae5d7588
4
- data.tar.gz: cc11ee12661f56ed7edefdb21761a585922756b80874f37b5968c0f3c7db5b8f
3
+ metadata.gz: ddbe148cf43cc5de663b5e174abbd4fa41fc7b16de9f60309b4881f876830d44
4
+ data.tar.gz: b66c2f4364b1215ff620c0153d2685c4ccdbdb738655499d68801860c5c6bb82
5
5
  SHA512:
6
- metadata.gz: cce9bdf292e20c825da20d7df50d831032df7fb7742937e436efd7be56c7caa04965da9b30af6e1742f1d26d31276b1c0784300a09ce3b2315c005f3c6f2dadd
7
- data.tar.gz: fc8f0069976b00b910b909a9136f6f31696ed111f0fd2f67d28fb35a3cc5b578be544eafbd696633b29d0075c50af560a43f9325eb4b2b0470109fc09a2741e1
6
+ metadata.gz: d130c38d1751918fd20b07310a3920199690dfe5be85833f6aaa4ea9a7352dc0c159b0297f933d745af9380366b5c9b49d41af4c7d3fa857c30d734a19e1e473
7
+ data.tar.gz: ea4b1f6e824c735be2503c7e05cad6974eec9c38667ef645cab0d5d83b0d77f2e0a1a58dd183c42247a138185b35307cd79b23c9ff374a4795e023474e9e06b5
@@ -7,6 +7,7 @@ module Fastlane
7
7
  def self.run(params)
8
8
  # INITIALIZE
9
9
  branch = Actions.git_branch()
10
+ default_platform = lane_context[SharedValues::DEFAULT_PLATFORM]
10
11
  last_commit_message = Actions.last_git_commit_message()
11
12
  final_version_array = []
12
13
  final_version_string = ""
@@ -62,6 +63,21 @@ module Fastlane
62
63
  rescue => exception
63
64
  puts exception
64
65
  ios_version_string = minimal_version_string
66
+ ensure
67
+ if (default_platform == :ios)
68
+ platform = Spaceship::ConnectAPI::Platform.map("ios")
69
+ app = Spaceship::ConnectAPI::App.find(params[:ios_app_identifier])
70
+ latest_version = app.get_latest_app_store_version(platform: platform)
71
+
72
+ v_state = latest_version.app_store_state
73
+ v_name = latest_version.version_string
74
+ v_name_array = v_name.split('.').map { |value| value.to_i }
75
+
76
+ if ((v_state == "WAITING_FOR_REVIEW" || v_state == "IN_REVIEW") && v_name_array.last > 0)
77
+ UI.error "App Store Connect is processing a hotfix! Version: #{v_name}; Status: #{v_state}"
78
+ exit(false)
79
+ end
80
+ end
65
81
  end
66
82
 
67
83
  # ANDROID
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module AutoVersionName
3
- VERSION = "0.2.1"
3
+ VERSION = "0.3.0"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-auto_version_name
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.1
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - gileadeteixeira
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-11-30 00:00:00.000000000 Z
11
+ date: 2024-02-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler