lokalise_manager 5.1.2 → 6.0.0
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/CHANGELOG.md +12 -0
- data/README.md +1 -1
- data/lib/lokalise_manager/global_config.rb +4 -4
- data/lib/lokalise_manager/task_definitions/base.rb +1 -1
- data/lib/lokalise_manager/version.rb +1 -1
- data/lokalise_manager.gemspec +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: f0df6efdcebd1ef7b1f3992a14c997d56859553cf0e1b089d43fe496f479bb1e
|
4
|
+
data.tar.gz: 762127da9ea96e1b5ad532a5217d0f06556b3d9f61b65f722f79a50a406bba23
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 42c3990642e4598cc746f1f991d57bceb1793b0de6f8a9ff8b7a33d42194c47a9d84243ee045658a4925dda13d2b6ee63bb0464bd48c8094951b60c2b83e8c9b
|
7
|
+
data.tar.gz: 156793b3c527be7e88fa4790db675f98958ba80a2be717259f4e3fca937a1369b9660210d8778b727cce1249f9237873507c6800e88eec33d40aac3bf9b42c8a
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,17 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## 6.0.0 (29-Nov-2024)
|
4
|
+
|
5
|
+
* **Breaking change**: rename the `timeouts` config method to `additional_client_opts`. It has the same usage but now enables you to set both client timeouts and override the API host to send requests to.
|
6
|
+
|
7
|
+
```ruby
|
8
|
+
additional_client_opts: {
|
9
|
+
open_timeout: 100,
|
10
|
+
timeout: 500,
|
11
|
+
api_host: 'http://example.com/api'
|
12
|
+
}
|
13
|
+
```
|
14
|
+
|
3
15
|
## 5.1.2 (01-Nov-2024)
|
4
16
|
|
5
17
|
* Update dependencies
|
data/README.md
CHANGED
@@ -108,7 +108,7 @@ Please don't forget that Lokalise API has rate limiting and you cannot send more
|
|
108
108
|
* `project_id` (`string`, required) — Lokalise project ID. You must have import/export permissions in the specified project.
|
109
109
|
* `locales_path` (`string`) — path to the directory with your translation files. Defaults to `"#{Dir.getwd}/locales"`.
|
110
110
|
* `branch` (`string`) — Lokalise project branch to use. Defaults to `""` (no branch is provided).
|
111
|
-
* `
|
111
|
+
* `additional_client_opts` (`hash`) — set [request timeouts and API host for the Lokalise client](https://lokalise.github.io/ruby-lokalise-api/additional_info/customization). By default, requests have no timeouts and the API host is not overriden: `{open_timeout: nil, timeout: nil, api_host: nil}`. Timeout values are in seconds.
|
112
112
|
* `silent_mode` (`boolean`) — whether you would like to output debugging information to `$stdout`. By default, after a task is performed, a short notification message will be printed out to the terminal. When set to `false`, notifications won't be printed. Please note that currently `import_safe_mode` has higher priority. Even if you enable `silent_mode`, and the `import_safe_mode` is enabled as well, you will be prompted to confirm the import operation if the target directory is not empty.
|
113
113
|
|
114
114
|
### Import config
|
@@ -7,7 +7,7 @@ module LokaliseManager
|
|
7
7
|
class << self
|
8
8
|
attr_accessor :api_token, :project_id
|
9
9
|
attr_writer :import_opts, :import_safe_mode, :export_opts, :locales_path,
|
10
|
-
:file_ext_regexp, :skip_file_export, :branch, :
|
10
|
+
:file_ext_regexp, :skip_file_export, :branch, :additional_client_opts,
|
11
11
|
:translations_loader, :translations_converter, :lang_iso_inferer,
|
12
12
|
:max_retries_export, :max_retries_import, :use_oauth2_token, :silent_mode,
|
13
13
|
:raise_on_export_fail
|
@@ -42,9 +42,9 @@ module LokaliseManager
|
|
42
42
|
@branch || ''
|
43
43
|
end
|
44
44
|
|
45
|
-
# Return API
|
46
|
-
def
|
47
|
-
@
|
45
|
+
# Return additional API client options
|
46
|
+
def additional_client_opts
|
47
|
+
@additional_client_opts || {}
|
48
48
|
end
|
49
49
|
|
50
50
|
# Return the max retries for export
|
@@ -39,7 +39,7 @@ module LokaliseManager
|
|
39
39
|
|
40
40
|
# Creates a Lokalise API client based on configuration.
|
41
41
|
def create_api_client
|
42
|
-
client_opts = [config.api_token, config.
|
42
|
+
client_opts = [config.api_token, config.additional_client_opts]
|
43
43
|
client_method = config.use_oauth2_token ? :oauth2_client : :client
|
44
44
|
|
45
45
|
::RubyLokaliseApi.public_send(client_method, *client_opts)
|
data/lokalise_manager.gemspec
CHANGED
@@ -23,7 +23,7 @@ Gem::Specification.new do |spec|
|
|
23
23
|
spec.extra_rdoc_files = ['README.md']
|
24
24
|
spec.require_paths = ['lib']
|
25
25
|
|
26
|
-
spec.add_dependency 'ruby-lokalise-api', '~> 9.
|
26
|
+
spec.add_dependency 'ruby-lokalise-api', '~> 9.3'
|
27
27
|
spec.add_dependency 'rubyzip', '~> 2.3'
|
28
28
|
spec.add_dependency 'zeitwerk', '~> 2.4'
|
29
29
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lokalise_manager
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 6.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ilya Krukowski
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-11-
|
11
|
+
date: 2024-11-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: ruby-lokalise-api
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '9.
|
19
|
+
version: '9.3'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '9.
|
26
|
+
version: '9.3'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rubyzip
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -238,7 +238,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
238
238
|
- !ruby/object:Gem::Version
|
239
239
|
version: '0'
|
240
240
|
requirements: []
|
241
|
-
rubygems_version: 3.5.
|
241
|
+
rubygems_version: 3.5.23
|
242
242
|
signing_key:
|
243
243
|
specification_version: 4
|
244
244
|
summary: Lokalise integration for Ruby
|