firim 0.2.5 → 0.2.6

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: 2c80df0584f730a7a566c182fa5ef6d437a916d85fb1cff742c6d788b16235df
4
- data.tar.gz: 6ec7bc06b2ebb57bb0a05540383829faa206fb742f5b75c9aff55ad3cf6680d3
3
+ metadata.gz: 99d4a5e75424bb3b1bbfdccf40ccaf363ad04a2bdccc92912da706716a63119c
4
+ data.tar.gz: 5a185dc631b20f68dc485c6d877c153568e175be7e4e99ab0cb0518de3a0b728
5
5
  SHA512:
6
- metadata.gz: 05d6dc9a9221d71a98820192f4545cf1f3ff58165c2abfa984e3f3ab4d825170ac45e1523cfbd563774c80a8ac4f1fc7ae5c300e5fc485cff141d7ec5d2b31a8
7
- data.tar.gz: 2ec46da632712e5c33181d57c8fc3284001f8e2de09f30fefef0b4505e09ee17cfadae253e3d62f0f7f5ce2c72ed68e0e9d7129d59fcd84608150a0dc0a73990
6
+ metadata.gz: 6f9d2e3d57c1b69f97ba74e26a2e27fe21754c897eb01d9ac07540293d0dff486cbbc8dbe7671c70c2b5020701bc33aabd3f03bc977a426b07b51841e7cb5cde
7
+ data.tar.gz: ce37927d5f4dea8127b5fc3c04e386252d6f5aa24c0d40432c64a14ddd19f2c5d1cbf9be120bc6d05654c2def91d19fd85303fba571f0ff11db09a11784a268f
data/README.md CHANGED
@@ -1,6 +1,8 @@
1
1
  ***Important***
2
2
 
3
- ***For the reason of fir.im had changed the Base URL, pls set `firim_api_url` to `http://api.jappstore.com/` or `http://api.bq04.com`.*** [issue](https://github.com/whlsxl/firim/issues/26)
3
+ ***For the reason of fir.im had changed the Base URL, pls set `firim_api_url` to `http://fir-api.fircli.cn/` or `http://api.bq04.com`.*** [issue](https://github.com/whlsxl/firim/issues/26)
4
+
5
+ From v0.2.5, the default `firim_api_url` set to `http://api.bq04.com`.
4
6
 
5
7
  # Firim
6
8
 
@@ -21,6 +21,12 @@ module Firim
21
21
  FastlaneCore::ConfigItem.new(key: :firim_username,
22
22
  optional: true,
23
23
  description: "fir.im username, a sign for identify different token"),
24
+
25
+ FastlaneCore::ConfigItem.new(key: :download_page_prefix,
26
+ short_option: "-p",
27
+ optional: true,
28
+ default_value: "http://d.firim.top/",
29
+ description: "fir.im user api token"),
24
30
  # Content path
25
31
  FastlaneCore::ConfigItem.new(key: :ipa,
26
32
  optional: true,
@@ -63,6 +63,7 @@ module Firim
63
63
  @app_info.merge!( update_app_info(@app_info["id"]))
64
64
  write_app_info_to_file
65
65
  options = @app_info
66
+ options[:download_page_url] = download_url
66
67
  FastlaneCore::PrintTable.print_values(config: options, title: "#{@app_info["name"]}'s' App Info")
67
68
  end
68
69
 
@@ -70,11 +71,20 @@ module Firim
70
71
  file_path = self.options[:app_info_to_file_path]
71
72
  return if file_path == nil
72
73
  File.open(file_path, "at") do |f|
73
- f.write("#{@app_info["name"]}: http://fir.im/#{@app_info["short"]} \n")
74
+ d_url = download_url
75
+ f.write("#{@app_info["name"]}: #{d_url}\n")
74
76
  UI.success "Write app info to #{file_path} successed!"
75
77
  end
76
78
  end
77
79
 
80
+ def download_url
81
+ prefix = self.options[:download_page_prefix]
82
+ if prefix[1..-1] != "/"
83
+ return "#{prefix}/#{@app_info["short"]}"
84
+ end
85
+ return "#{prefix}#{@app_info["short"]}"
86
+ end
87
+
78
88
  def validation_response response_data
79
89
  error_code = response_data['code'].to_i
80
90
  return if error_code == 0
@@ -1,3 +1,3 @@
1
1
  module Firim
2
- VERSION = "0.2.5"
2
+ VERSION = "0.2.6"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: firim
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.5
4
+ version: 0.2.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - whlsxl
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-05-14 00:00:00.000000000 Z
11
+ date: 2020-12-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fastlane