fastlane-plugin-taiwan_number_one 0.2.6 → 0.2.7
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:
|
4
|
-
data.tar.gz: '
|
3
|
+
metadata.gz: 29c9d03d5a2a3660d0b4e40788ed3d4459c08f2334d8d4f66350df8dbd58c8d9
|
4
|
+
data.tar.gz: '05458abd7384ce522b853a35d69de92bae36bbaab821f400d69881d1f8e59c70'
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9b972ebe636be3276847abf501996e662822a163b4bee572b88557fa7477352f7e7aa3a83c160fdaca169dc9ad2ce3869a34c7527f7255b9f4daabf3a4daabc7
|
7
|
+
data.tar.gz: b98462a5fb3438b0bb3dc6c21586ef0af9e07e90f5c59c14b7c9a1ac78e457e562a807a1938f232782781925639d41c2c12624419307ac69ccc7dc597f562cae
|
data/README.md
CHANGED
@@ -10,6 +10,7 @@ This project is a [_fastlane_](https://github.com/fastlane/fastlane) plugin. To
|
|
10
10
|
fastlane add_plugin taiwan_number_one
|
11
11
|
```
|
12
12
|
|
13
|
+
Start from v0.2.7 we use this [workaround](https://github.com/fastlane/fastlane/issues/17283#issuecomment-711865915) to solve issue while using App Store Connect Api key.
|
13
14
|
## About taiwan_number_one
|
14
15
|
|
15
16
|
To approve or reject if status is `Pending Developer Release`, otherwise do nothing.
|
@@ -71,7 +71,7 @@ module Fastlane
|
|
71
71
|
case decision
|
72
72
|
when DicisionType::RELEASE
|
73
73
|
UI.message("decision is release")
|
74
|
-
result = release_version_if_possible(app: app, app_store_version: app_store_version)
|
74
|
+
result = release_version_if_possible(app: app, app_store_version: app_store_version, token: token)
|
75
75
|
when DicisionType::REJECT
|
76
76
|
UI.message("decision is reject")
|
77
77
|
result = reject_version_if_possible(app: app, app_store_version: app_store_version)
|
@@ -111,16 +111,26 @@ module Fastlane
|
|
111
111
|
end
|
112
112
|
end
|
113
113
|
|
114
|
-
def self.release_version_if_possible(app: nil, app_store_version: Spaceship::ConnectAPI::AppStoreVersion)
|
114
|
+
def self.release_version_if_possible(app: nil, app_store_version: Spaceship::ConnectAPI::AppStoreVersion, token: nil)
|
115
115
|
unless app
|
116
116
|
UI.user_error!("Could not find app with bundle identifier '#{params[:app_identifier]}' on account #{params[:username]}")
|
117
117
|
return ActionResult::DO_NOTHING
|
118
118
|
end
|
119
119
|
|
120
120
|
begin
|
121
|
-
|
122
|
-
|
123
|
-
|
121
|
+
if token
|
122
|
+
now = Time.now
|
123
|
+
release_date_string = now.strftime("%Y-%m-%dT%H:00%:z")
|
124
|
+
app_store_version.update(attributes: {
|
125
|
+
earliest_release_date: release_date_string,
|
126
|
+
release_type: Spaceship::ConnectAPI::AppStoreVersion::ReleaseType::SCHEDULED
|
127
|
+
})
|
128
|
+
return ActionResult::SUCCESS
|
129
|
+
else
|
130
|
+
app_store_version.create_app_store_version_release_request
|
131
|
+
UI.message("release version #{app_store_version.version_string} successfully!")
|
132
|
+
return ActionResult::SUCCESS
|
133
|
+
end
|
124
134
|
rescue => e
|
125
135
|
UI.user_error!("An error occurred while releasing version #{app_store_version}, #{e.message}\n#{e.backtrace.join("\n")}")
|
126
136
|
return ActionResult::DO_NOTHING
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fastlane-plugin-taiwan_number_one
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- andrew54068
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-04-09 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: pry
|