fastlane-plugin-rustore_developer 0.2.12 → 0.3.1

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: 7a3598a51af0a4350981f4bf8f39233d74d9503c6615a03edda751d0e266595d
4
- data.tar.gz: 3b8d74c88a394a063e459ba7b8a49d508907b4a8691b4c8348635941372ccada
3
+ metadata.gz: 4c395b2d1c3bc9975ac41c1c3af329160363d0cc14da5b134d76bc81c1323685
4
+ data.tar.gz: afeee1b001b6819b0c0bc84e6bca475ee0b2cac2c5c80f8e2d523981a523477e
5
5
  SHA512:
6
- metadata.gz: 336d812e6fa1d6623202050c21ea3860fcd61a6a08b12794b987a3d57d7f82410386402b1dae4212ddaa434aae678d2b7c6d5de1471ff9160afe4aeb4063eeee
7
- data.tar.gz: b5c929b405f1360acefdfe830c4f816f80ee42de2369c83b268c822b289f77b7e0e13dcf1f06035de5413b288f95b6d1aa67fd724ae6ae30efdb8f2b49a67b61
6
+ metadata.gz: f31b22723ed762ee134f45e2c340ad4d66a21ae331705f5c0dac9cde6d585e30815029d16d40e78fbc90b0799491b39260ad7ecac9ada41f2b9a6d2fba753738
7
+ data.tar.gz: ce59893ce3d290f2d7e5d52497bc7a7ce6e0b876647ded311dcc7b2b7d5e8da53795dd7a569a560357ca2f3a4fcdf174f499e48c49005d5a666295e70a353a01
@@ -9,7 +9,7 @@ module Fastlane
9
9
  class RustoreDeveloperAuthAction < Action
10
10
 
11
11
  def self.run(params)
12
- token = Helper::RustoreDeveloperHelper.getAccessToken(params[:company_id], params[:key_path])
12
+ token = Helper::RustoreDeveloperHelper.getAccessToken(params[:key_id], params[:key_path])
13
13
  Actions.lane_context[SharedValues::RUSTORE_DEVELOPER_ACCESS_TOKEN] = token
14
14
  return token
15
15
  end
@@ -33,9 +33,9 @@ module Fastlane
33
33
 
34
34
  def self.available_options
35
35
  [
36
- FastlaneCore::ConfigItem.new(key: :company_id,
37
- env_name: "RUSTORE_COMPANY_ID",
38
- description: "Company ID",
36
+ FastlaneCore::ConfigItem.new(key: :key_id,
37
+ env_name: "RUSTORE_KEY_ID",
38
+ description: "Key ID",
39
39
  optional: false,
40
40
  type: String),
41
41
  FastlaneCore::ConfigItem.new(key: :key_path,
@@ -6,11 +6,11 @@ module Fastlane
6
6
  class RustoreDeveloperUploadAction < Action
7
7
 
8
8
  def self.run(params)
9
- return Helper::RustoreDeveloperHelper.uploadAPK(params[:token], params[:package], params[:version], params[:file_path])
9
+ return Helper::RustoreDeveloperHelper.uploadAPK(params[:token], params[:package], params[:version], params[:apk_path])
10
10
  end
11
11
 
12
12
  def self.description
13
- "RUSTORE: Upload an APK package"
13
+ "RUSTORE: Upload an APK package for version"
14
14
  end
15
15
 
16
16
  def self.authors
@@ -47,7 +47,8 @@ module Fastlane
47
47
  optional: true,
48
48
  type: String,
49
49
  default_value: Actions.lane_context[SharedValues::RUSTORE_DEVELOPER_DRAFT_VERSION]),
50
- FastlaneCore::ConfigItem.new(key: :file_path,
50
+ FastlaneCore::ConfigItem.new(key: :apk_path,
51
+ env_name: "RUSTORE_APK_PATH",
51
52
  description: "File path of APK artifact",
52
53
  optional: false ,
53
54
  type: String)
@@ -14,24 +14,24 @@ module Fastlane
14
14
  # return '2023-08-23T09:00:32.939+03:00'
15
15
  end
16
16
 
17
- def self.getSignatureEncoded(company_id, timestamp, key_path)
17
+ def self.getSignatureEncoded(key_id, timestamp, key_path)
18
18
  private_key = OpenSSL::PKey.read(File.read(key_path))
19
- data = company_id + timestamp
19
+ data = key_id + timestamp
20
20
  signature = private_key.sign("SHA512", data)
21
21
  encoded = Base64.strict_encode64(signature)
22
22
  return encoded
23
23
  end
24
24
 
25
- def self.getAccessToken(company_id, key_path)
25
+ def self.getAccessToken(key_id, key_path)
26
26
  UI.important("Getting access token ...")
27
27
  timestamp = getTimestamp()
28
- sign = getSignatureEncoded(company_id, timestamp, key_path)
28
+ sign = getSignatureEncoded(key_id, timestamp, key_path)
29
29
  uri = URI(BASE_URL + '/public/auth/')
30
30
  http = Net::HTTP.new(uri.host, uri.port)
31
31
  http.use_ssl = true
32
32
  req = Net::HTTP::Post.new(uri.path)
33
33
  req["Content-Type"] = "application/json"
34
- data = {'companyId': company_id, 'timestamp': timestamp, 'signature': sign}
34
+ data = {'keyId': key_id, 'timestamp': timestamp, 'signature': sign}
35
35
  req.body = data.to_json
36
36
  res = http.request(req)
37
37
  result_json = JSON.parse(res.body)
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module RustoreDeveloper
3
- VERSION = "0.2.12"
3
+ VERSION = "0.3.1"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-rustore_developer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.12
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - RimiX2
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-09-04 00:00:00.000000000 Z
11
+ date: 2024-11-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -187,7 +187,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
187
187
  - !ruby/object:Gem::Version
188
188
  version: '0'
189
189
  requirements: []
190
- rubygems_version: 3.1.6
190
+ rubygems_version: 3.4.19
191
191
  signing_key:
192
192
  specification_version: 4
193
193
  summary: RUSTORE beta API integration plugin