u3d 1.3.2 → 1.3.3
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 +4 -4
- data/.github_changelog_generator +1 -1
- data/Gemfile.lock +2 -2
- data/lib/u3d/hub_modules_parser.rb +1 -1
- data/lib/u3d/unity_versions.rb +1 -1
- data/lib/u3d/utils.rb +6 -0
- data/lib/u3d/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 79f773ac16b5e24ec6a48498f0e62abbe4ae90c21e9a565afe7689375dba359e
|
|
4
|
+
data.tar.gz: 27aad3e6f30b0aee9b5e02fd121253f3c6170752bc023108ab39e60faf85ba37
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4adcd91f22408edc31a15b57623160160fa34eb6493cc91c18881d43eb42b6b0d2a01e7f3ba387f99811c6c8bfdcdd1a9794a948965f0eaae1deda6cd44e68f1
|
|
7
|
+
data.tar.gz: cda628fa54363f7bebf1396ac0e0508f7a29625e8f99458d8ee0e5524e5da8139cb33571a5f4fa1ac59d3ff4d153fff33426faf027def254ef17e799977522e4
|
data/.github_changelog_generator
CHANGED
data/Gemfile.lock
CHANGED
|
@@ -54,7 +54,7 @@ module U3d
|
|
|
54
54
|
versions_and_paths = versions_and_paths.select { |a| a[0].parts[0] == vn.parts[0] && a[0].parts[1] == vn.parts[1] && a[0].parts[2] >= vn.parts[2] }
|
|
55
55
|
|
|
56
56
|
if versions_and_paths.empty?
|
|
57
|
-
UI.
|
|
57
|
+
UI.message "No closest version from UnityHub found for version #{version}"
|
|
58
58
|
return []
|
|
59
59
|
end
|
|
60
60
|
path = versions_and_paths.first[1]
|
data/lib/u3d/unity_versions.rb
CHANGED
|
@@ -64,7 +64,7 @@ module U3d
|
|
|
64
64
|
when Net::HTTPRedirection
|
|
65
65
|
# A session must be opened with the server before accessing forum
|
|
66
66
|
res = nil
|
|
67
|
-
cookie_str = ''
|
|
67
|
+
cookie_str = +''
|
|
68
68
|
# Store the name and value of the cookies returned by the server
|
|
69
69
|
response['set-cookie'].gsub(/\s+/, '').split(',').each do |c|
|
|
70
70
|
cookie_str << ("#{c.split(';', 2)[0]}; ")
|
data/lib/u3d/utils.rb
CHANGED
|
@@ -34,6 +34,9 @@ module U3d
|
|
|
34
34
|
# Regex to capture each part of a version string (0.0.0x0)
|
|
35
35
|
CSIDL_LOCAL_APPDATA = 0x001c
|
|
36
36
|
UNITY_VERSION_REGEX = /(\d+)(?:\.(\d+)(?:\.(\d+))?)?(?:(\w)(?:(\d+))?)?/.freeze
|
|
37
|
+
MOZILLA_AGENT_HEADER = {
|
|
38
|
+
'User-Agent' => 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:106.0) Gecko/20100101 Firefox/106.0'
|
|
39
|
+
}.freeze
|
|
37
40
|
|
|
38
41
|
class << self
|
|
39
42
|
def final_url(url, redirect_limit: 10)
|
|
@@ -56,6 +59,9 @@ module U3d
|
|
|
56
59
|
def follow_redirects(url, redirect_limit: 10, http_method: :get, request_headers: {}, &block)
|
|
57
60
|
raise 'Too many redirections' if redirect_limit.zero?
|
|
58
61
|
|
|
62
|
+
# Unity blocks the default Ruby agent, use another one
|
|
63
|
+
request_headers = MOZILLA_AGENT_HEADER.merge(request_headers)
|
|
64
|
+
|
|
59
65
|
response = nil
|
|
60
66
|
request = nil
|
|
61
67
|
uri = URI(url)
|
data/lib/u3d/version.rb
CHANGED
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
## --- END LICENSE BLOCK ---
|
|
24
24
|
|
|
25
25
|
module U3d
|
|
26
|
-
VERSION = '1.3.
|
|
26
|
+
VERSION = '1.3.3'
|
|
27
27
|
DESCRIPTION = 'Provides numerous tools for installing, managing and running the Unity game engine from command line.'
|
|
28
28
|
UNITY_VERSIONS_NOTE = "Unity uses the following version formatting: 0.0.0x0. The \'x\' can takes different values:\n"\
|
|
29
29
|
"\t. 'f' are the main release candidates for Unity\n"\
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: u3d
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.3.
|
|
4
|
+
version: 1.3.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Jerome Lacoste
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: exe
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date:
|
|
12
|
+
date: 2023-01-04 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: colored
|
|
@@ -537,7 +537,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
537
537
|
- !ruby/object:Gem::Version
|
|
538
538
|
version: '0'
|
|
539
539
|
requirements: []
|
|
540
|
-
rubygems_version: 3.
|
|
540
|
+
rubygems_version: 3.0.9
|
|
541
541
|
signing_key:
|
|
542
542
|
specification_version: 4
|
|
543
543
|
summary: U3d
|