lokalise_rails 0.2.0 → 1.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +30 -0
- data/README.md +87 -27
- data/lib/generators/lokalise_rails/install_generator.rb +1 -1
- data/lib/generators/templates/lokalise_rails_config.rb +46 -25
- data/lib/lokalise_rails.rb +69 -19
- data/lib/lokalise_rails/railtie.rb +1 -3
- data/lib/lokalise_rails/task_definition/base.rb +51 -11
- data/lib/lokalise_rails/task_definition/exporter.rb +78 -0
- data/lib/lokalise_rails/task_definition/importer.rb +75 -15
- data/lib/lokalise_rails/version.rb +2 -2
- data/lib/tasks/lokalise_rails_tasks.rake +5 -6
- data/lokalise_rails.gemspec +5 -7
- data/spec/dummy/config/application.rb +2 -2
- data/spec/dummy/config/environments/test.rb +1 -3
- data/spec/dummy/config/lokalise_rails.rb +4 -28
- data/spec/lib/generators/lokalise_rails/install_generator_spec.rb +1 -1
- data/spec/lib/lokalise_rails/task_definition/base_spec.rb +85 -0
- data/spec/lib/lokalise_rails/task_definition/exporter_spec.rb +165 -0
- data/spec/lib/lokalise_rails/task_definition/importer_spec.rb +49 -0
- data/spec/lib/lokalise_rails_spec.rb +62 -7
- data/spec/lib/tasks/export_task_spec.rb +7 -0
- data/spec/lib/tasks/import_task_spec.rb +46 -20
- data/spec/spec_helper.rb +8 -5
- data/spec/support/file_manager.rb +81 -0
- data/spec/support/rake_utils.rb +4 -0
- data/spec/support/spec_addons.rb +11 -0
- metadata +29 -48
- data/spec/lib/lokalise_rails/importer_spec.rb +0 -31
- data/spec/support/file_utils.rb +0 -27
@@ -0,0 +1,49 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
describe LokaliseRails::TaskDefinition::Importer do
|
4
|
+
describe '.open_and_process_zip' do
|
5
|
+
let(:faulty_trans) { "#{Rails.root}/public/faulty_trans.zip" }
|
6
|
+
|
7
|
+
it 'rescues from errors during file processing' do
|
8
|
+
expect(-> { described_class.open_and_process_zip(faulty_trans) }).
|
9
|
+
to output(/Psych::DisallowedClass/).to_stdout
|
10
|
+
end
|
11
|
+
end
|
12
|
+
|
13
|
+
describe '.download_files' do
|
14
|
+
it 'returns a proper download URL' do
|
15
|
+
allow_project_id '189934715f57a162257d74.88352370' do
|
16
|
+
response = VCR.use_cassette('download_files') do
|
17
|
+
described_class.download_files
|
18
|
+
end
|
19
|
+
|
20
|
+
expect(response['project_id']).to eq('189934715f57a162257d74.88352370')
|
21
|
+
expect(response['bundle_url']).to include('s3-eu-west-1.amazonaws.com')
|
22
|
+
end
|
23
|
+
end
|
24
|
+
|
25
|
+
it 'rescues from errors during file download' do
|
26
|
+
allow_project_id 'invalid'
|
27
|
+
VCR.use_cassette('download_files_error') do
|
28
|
+
expect(-> { described_class.download_files }).
|
29
|
+
to output(/Lokalise::Error::BadRequest/).to_stdout
|
30
|
+
end
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
describe '.import!' do
|
35
|
+
it 'halts when the API key is not set' do
|
36
|
+
allow(LokaliseRails).to receive(:api_token).and_return(nil)
|
37
|
+
expect(-> { described_class.import! }).to output(/API token is not set/).to_stdout
|
38
|
+
expect(LokaliseRails).to have_received(:api_token)
|
39
|
+
expect(count_translations).to eq(0)
|
40
|
+
end
|
41
|
+
|
42
|
+
it 'halts when the project_id is not set' do
|
43
|
+
allow_project_id nil do
|
44
|
+
expect(-> { described_class.import! }).to output(/Project ID is not set/).to_stdout
|
45
|
+
expect(count_translations).to eq(0)
|
46
|
+
end
|
47
|
+
end
|
48
|
+
end
|
49
|
+
end
|
@@ -1,40 +1,95 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
3
|
describe LokaliseRails do
|
4
|
-
it '
|
4
|
+
it 'returns a proper version' do
|
5
5
|
expect(LokaliseRails::VERSION).to be_a(String)
|
6
6
|
end
|
7
7
|
|
8
|
+
it 'is possible to provide config options' do
|
9
|
+
described_class.config do |c|
|
10
|
+
expect(c).to eq(described_class)
|
11
|
+
end
|
12
|
+
end
|
13
|
+
|
8
14
|
describe 'parameters' do
|
9
15
|
let(:fake_class) { class_double('LokaliseRails') }
|
10
16
|
|
11
17
|
it 'is possible to set project_id' do
|
12
|
-
|
18
|
+
allow(fake_class).to receive(:project_id=).with('123.abc')
|
13
19
|
fake_class.project_id = '123.abc'
|
14
20
|
end
|
15
21
|
|
22
|
+
it 'is possible to set file_ext_regexp' do
|
23
|
+
allow(fake_class).to receive(:file_ext_regexp=).with(Regexp.new('.*'))
|
24
|
+
fake_class.file_ext_regexp = Regexp.new('.*')
|
25
|
+
end
|
26
|
+
|
16
27
|
it 'is possible to set import_opts' do
|
17
|
-
|
28
|
+
allow(fake_class).to receive(:import_opts=).with(duck_type(:each))
|
18
29
|
fake_class.import_opts = {
|
19
30
|
format: 'json',
|
20
31
|
indentation: '8sp'
|
21
32
|
}
|
22
33
|
end
|
23
34
|
|
35
|
+
it 'is possible to set export_opts' do
|
36
|
+
allow(fake_class).to receive(:export_opts=).with(duck_type(:each))
|
37
|
+
fake_class.export_opts = {
|
38
|
+
convert_placeholders: true,
|
39
|
+
detect_icu_plurals: true
|
40
|
+
}
|
41
|
+
end
|
42
|
+
|
43
|
+
it 'is possible to set branch' do
|
44
|
+
allow(fake_class).to receive(:branch=).with('custom')
|
45
|
+
fake_class.branch = 'custom'
|
46
|
+
end
|
47
|
+
|
48
|
+
it 'is possible to set timeouts' do
|
49
|
+
allow(fake_class).to receive(:timeouts=).with(duck_type(:each))
|
50
|
+
fake_class.timeouts = {
|
51
|
+
open_timeout: 100,
|
52
|
+
timeout: 500
|
53
|
+
}
|
54
|
+
end
|
55
|
+
|
24
56
|
it 'is possible to set import_safe_mode' do
|
25
|
-
|
57
|
+
allow(fake_class).to receive(:import_safe_mode=).with(true)
|
26
58
|
fake_class.import_safe_mode = true
|
27
59
|
end
|
28
60
|
|
29
61
|
it 'is possible to set api_token' do
|
30
|
-
|
62
|
+
allow(fake_class).to receive(:api_token=).with('abc')
|
31
63
|
fake_class.api_token = 'abc'
|
32
64
|
end
|
33
65
|
|
34
66
|
it 'is possible to override locales_path' do
|
35
|
-
|
67
|
+
allow(fake_class).to receive(:locales_path=).with('/demo/path')
|
68
|
+
fake_class.locales_path = '/demo/path'
|
69
|
+
end
|
70
|
+
|
71
|
+
it 'is possible to set skip_file_export' do
|
72
|
+
cond = ->(f) { f.nil? }
|
73
|
+
allow(fake_class).to receive(:skip_file_export=).with(cond)
|
74
|
+
fake_class.skip_file_export = cond
|
75
|
+
end
|
76
|
+
|
77
|
+
it 'is possible to set translations_loader' do
|
78
|
+
runner = ->(f) { f.to_json }
|
79
|
+
allow(fake_class).to receive(:translations_loader=).with(runner)
|
80
|
+
fake_class.translations_loader = runner
|
81
|
+
end
|
82
|
+
|
83
|
+
it 'is possible to set translations_converter' do
|
84
|
+
runner = ->(f) { f.to_json }
|
85
|
+
allow(fake_class).to receive(:translations_converter=).with(runner)
|
86
|
+
fake_class.translations_converter = runner
|
87
|
+
end
|
36
88
|
|
37
|
-
|
89
|
+
it 'is possible to set lang_iso_inferer' do
|
90
|
+
runner = ->(f) { f.to_json }
|
91
|
+
allow(fake_class).to receive(:lang_iso_inferer=).with(runner)
|
92
|
+
fake_class.lang_iso_inferer = runner
|
38
93
|
end
|
39
94
|
end
|
40
95
|
end
|
@@ -3,6 +3,10 @@
|
|
3
3
|
require 'fileutils'
|
4
4
|
|
5
5
|
RSpec.describe LokaliseRails do
|
6
|
+
let(:loc_path) { described_class.locales_path }
|
7
|
+
let(:local_trans) { "#{Rails.root}/public/trans.zip" }
|
8
|
+
let(:remote_trans) { 'https://github.com/bodrovis/lokalise_rails/blob/master/spec/dummy/public/trans.zip?raw=true' }
|
9
|
+
|
6
10
|
context 'when directory is empty' do
|
7
11
|
before do
|
8
12
|
mkdir_locales
|
@@ -13,70 +17,92 @@ RSpec.describe LokaliseRails do
|
|
13
17
|
rm_translation_files
|
14
18
|
end
|
15
19
|
|
16
|
-
it 'is callable' do
|
17
|
-
|
20
|
+
it 'import rake task is callable' do
|
21
|
+
allow(LokaliseRails::TaskDefinition::Importer).to receive(
|
18
22
|
:download_files
|
19
23
|
).and_return(
|
20
24
|
{
|
21
25
|
'project_id' => '123.abc',
|
22
|
-
'bundle_url' =>
|
26
|
+
'bundle_url' => local_trans
|
23
27
|
}
|
24
28
|
)
|
25
29
|
|
26
30
|
expect(import_executor).to output(/complete!/).to_stdout
|
27
31
|
|
28
32
|
expect(count_translations).to eq(4)
|
29
|
-
|
30
|
-
|
31
|
-
|
33
|
+
expect(LokaliseRails::TaskDefinition::Importer).to have_received(:download_files)
|
34
|
+
expect_file_exist loc_path, 'en/nested/main_en.yml'
|
35
|
+
expect_file_exist loc_path, 'en/nested/deep/secondary_en.yml'
|
36
|
+
expect_file_exist loc_path, 'ru/main_ru.yml'
|
32
37
|
end
|
33
38
|
|
34
|
-
it 'downloads ZIP archive properly' do
|
35
|
-
|
39
|
+
it 'import rake task downloads ZIP archive properly' do
|
40
|
+
allow(LokaliseRails::TaskDefinition::Importer).to receive(
|
36
41
|
:download_files
|
37
42
|
).and_return(
|
38
43
|
{
|
39
44
|
'project_id' => '123.abc',
|
40
|
-
'bundle_url' =>
|
45
|
+
'bundle_url' => remote_trans
|
41
46
|
}
|
42
47
|
)
|
43
48
|
|
44
49
|
expect(import_executor).to output(/complete!/).to_stdout
|
45
50
|
|
51
|
+
expect(LokaliseRails::TaskDefinition::Importer).to have_received(:download_files)
|
46
52
|
expect(count_translations).to eq(4)
|
47
|
-
|
48
|
-
|
49
|
-
|
53
|
+
expect_file_exist loc_path, 'en/nested/main_en.yml'
|
54
|
+
expect_file_exist loc_path, 'en/nested/deep/secondary_en.yml'
|
55
|
+
expect_file_exist loc_path, 'ru/main_ru.yml'
|
50
56
|
end
|
51
57
|
end
|
52
58
|
|
53
|
-
context 'when directory is not empty' do
|
59
|
+
context 'when directory is not empty and safe mode enabled' do
|
54
60
|
before :all do
|
55
61
|
mkdir_locales
|
56
|
-
rm_translation_files
|
57
|
-
temp_file = File.join described_class.locales_path, 'kill.me'
|
58
|
-
File.open(temp_file, 'w+') { |file| file.write('temp') }
|
59
62
|
described_class.import_safe_mode = true
|
60
63
|
end
|
61
64
|
|
65
|
+
before do
|
66
|
+
rm_translation_files
|
67
|
+
add_translation_files!
|
68
|
+
end
|
69
|
+
|
62
70
|
after :all do
|
63
71
|
rm_translation_files
|
64
72
|
described_class.import_safe_mode = false
|
65
73
|
end
|
66
74
|
|
67
|
-
it '
|
68
|
-
|
75
|
+
it 'import proceeds when the user agrees' do
|
76
|
+
allow(LokaliseRails::TaskDefinition::Importer).to receive(
|
69
77
|
:download_files
|
70
78
|
).and_return(
|
71
79
|
{
|
72
80
|
'project_id' => '123.abc',
|
73
|
-
'bundle_url' =>
|
81
|
+
'bundle_url' => local_trans
|
74
82
|
}
|
75
83
|
)
|
76
|
-
|
84
|
+
|
85
|
+
allow($stdin).to receive(:gets).and_return('Y')
|
77
86
|
expect(import_executor).to output(/is not empty/).to_stdout
|
78
87
|
|
79
88
|
expect(count_translations).to eq(5)
|
89
|
+
expect($stdin).to have_received(:gets)
|
90
|
+
expect(LokaliseRails::TaskDefinition::Importer).to have_received(:download_files)
|
91
|
+
expect_file_exist loc_path, 'en/nested/main_en.yml'
|
92
|
+
expect_file_exist loc_path, 'en/nested/deep/secondary_en.yml'
|
93
|
+
expect_file_exist loc_path, 'ru/main_ru.yml'
|
94
|
+
end
|
95
|
+
|
96
|
+
it 'import halts when a user chooses not to proceed' do
|
97
|
+
allow(LokaliseRails::TaskDefinition::Importer).to receive(
|
98
|
+
:download_files
|
99
|
+
).at_most(0).times
|
100
|
+
allow($stdin).to receive(:gets).and_return('N')
|
101
|
+
expect(import_executor).to output(/is not empty/).to_stdout
|
102
|
+
|
103
|
+
expect(LokaliseRails::TaskDefinition::Importer).not_to have_received(:download_files)
|
104
|
+
expect($stdin).to have_received(:gets)
|
105
|
+
expect(count_translations).to eq(1)
|
80
106
|
end
|
81
107
|
end
|
82
108
|
end
|
data/spec/spec_helper.rb
CHANGED
@@ -2,6 +2,7 @@
|
|
2
2
|
|
3
3
|
require 'dotenv/load'
|
4
4
|
require 'simplecov'
|
5
|
+
|
5
6
|
SimpleCov.start 'rails' do
|
6
7
|
add_filter 'spec/'
|
7
8
|
add_filter '.github/'
|
@@ -19,16 +20,18 @@ Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].sort.each { |f| require f }
|
|
19
20
|
|
20
21
|
# Configure Rails Environment
|
21
22
|
ENV['RAILS_ENV'] = 'test'
|
22
|
-
|
23
23
|
require_relative '../spec/dummy/config/environment'
|
24
|
-
ActiveRecord::Migrator.migrations_paths = [File.expand_path('../spec/dummy/db/migrate', __dir__)]
|
25
24
|
ENV['RAILS_ROOT'] ||= "#{File.dirname(__FILE__)}../../../spec/dummy"
|
26
25
|
|
27
|
-
require 'rspec/rails'
|
28
|
-
|
29
26
|
RSpec.configure do |config|
|
30
|
-
config.include
|
27
|
+
config.include FileManager
|
31
28
|
config.include RakeUtils
|
29
|
+
config.include SpecAddons
|
32
30
|
end
|
33
31
|
|
32
|
+
# rubocop:disable Style/MixinUsage
|
33
|
+
include FileManager
|
34
|
+
# rubocop:enable Style/MixinUsage
|
35
|
+
|
36
|
+
add_config!
|
34
37
|
Rails.application.load_tasks
|
@@ -0,0 +1,81 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
require 'fileutils'
|
4
|
+
|
5
|
+
module FileManager
|
6
|
+
def expect_file_exist(path, file)
|
7
|
+
file_path = File.join path, file
|
8
|
+
expect(File.file?(file_path)).to be true
|
9
|
+
end
|
10
|
+
|
11
|
+
def mkdir_locales
|
12
|
+
FileUtils.mkdir_p(LokaliseRails.locales_path) unless File.directory?(LokaliseRails.locales_path)
|
13
|
+
end
|
14
|
+
|
15
|
+
def rm_translation_files
|
16
|
+
FileUtils.rm_rf locales_dir
|
17
|
+
end
|
18
|
+
|
19
|
+
def locales_dir
|
20
|
+
Dir["#{LokaliseRails.locales_path}/**/*"]
|
21
|
+
end
|
22
|
+
|
23
|
+
def count_translations
|
24
|
+
locales_dir.count { |file| File.file?(file) }
|
25
|
+
end
|
26
|
+
|
27
|
+
def add_translation_files!(with_ru: false)
|
28
|
+
FileUtils.mkdir_p "#{Rails.root}/config/locales/nested"
|
29
|
+
File.open("#{Rails.root}/config/locales/nested/en.yml", 'w+:UTF-8') do |f|
|
30
|
+
f.write en_data
|
31
|
+
end
|
32
|
+
|
33
|
+
return unless with_ru
|
34
|
+
|
35
|
+
File.open("#{Rails.root}/config/locales/ru.yml", 'w+:UTF-8') do |f|
|
36
|
+
f.write ru_data
|
37
|
+
end
|
38
|
+
end
|
39
|
+
|
40
|
+
def add_config!
|
41
|
+
data = <<~DATA
|
42
|
+
require 'lokalise_rails'
|
43
|
+
LokaliseRails.config do |c|
|
44
|
+
c.api_token = ENV['LOKALISE_API_TOKEN']
|
45
|
+
c.project_id = ENV['LOKALISE_PROJECT_ID']
|
46
|
+
end
|
47
|
+
DATA
|
48
|
+
|
49
|
+
File.open("#{Rails.root}/config/lokalise_rails.rb", 'w+:UTF-8') do |f|
|
50
|
+
f.write data
|
51
|
+
end
|
52
|
+
end
|
53
|
+
|
54
|
+
def remove_config
|
55
|
+
FileUtils.remove_file config_file if File.file?(config_file)
|
56
|
+
end
|
57
|
+
|
58
|
+
def config_file
|
59
|
+
"#{Rails.root}/config/lokalise_rails.rb"
|
60
|
+
end
|
61
|
+
|
62
|
+
private
|
63
|
+
|
64
|
+
def en_data
|
65
|
+
<<~DATA
|
66
|
+
en:
|
67
|
+
my_key: "My value"
|
68
|
+
nested:
|
69
|
+
key: "Value 2"
|
70
|
+
DATA
|
71
|
+
end
|
72
|
+
|
73
|
+
def ru_data
|
74
|
+
<<~DATA
|
75
|
+
ru_RU:
|
76
|
+
my_key: "Моё значение"
|
77
|
+
nested:
|
78
|
+
key: "Значение 2"
|
79
|
+
DATA
|
80
|
+
end
|
81
|
+
end
|
data/spec/support/rake_utils.rb
CHANGED
@@ -0,0 +1,11 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module SpecAddons
|
4
|
+
def allow_project_id(value = ENV['LOKALISE_PROJECT_ID'])
|
5
|
+
allow(LokaliseRails).to receive(:project_id).and_return(value)
|
6
|
+
return unless block_given?
|
7
|
+
|
8
|
+
yield
|
9
|
+
expect(LokaliseRails).to have_received(:project_id)
|
10
|
+
end
|
11
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lokalise_rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 1.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ilya Bodrov
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-02-02 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: '
|
19
|
+
version: '4.0'
|
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: '
|
26
|
+
version: '4.0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rubyzip
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -44,14 +44,14 @@ dependencies:
|
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: '0.
|
47
|
+
version: '0.2'
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: '0.
|
54
|
+
version: '0.2'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: dotenv
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
@@ -72,14 +72,14 @@ dependencies:
|
|
72
72
|
requirements:
|
73
73
|
- - "~>"
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version: 6.0
|
75
|
+
version: 6.1.0
|
76
76
|
type: :development
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
80
|
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version: 6.0
|
82
|
+
version: 6.1.0
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: rake
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
@@ -108,34 +108,20 @@ dependencies:
|
|
108
108
|
- - "~>"
|
109
109
|
- !ruby/object:Gem::Version
|
110
110
|
version: '3.6'
|
111
|
-
- !ruby/object:Gem::Dependency
|
112
|
-
name: rspec-rails
|
113
|
-
requirement: !ruby/object:Gem::Requirement
|
114
|
-
requirements:
|
115
|
-
- - "~>"
|
116
|
-
- !ruby/object:Gem::Version
|
117
|
-
version: '4.0'
|
118
|
-
type: :development
|
119
|
-
prerelease: false
|
120
|
-
version_requirements: !ruby/object:Gem::Requirement
|
121
|
-
requirements:
|
122
|
-
- - "~>"
|
123
|
-
- !ruby/object:Gem::Version
|
124
|
-
version: '4.0'
|
125
111
|
- !ruby/object:Gem::Dependency
|
126
112
|
name: rubocop
|
127
113
|
requirement: !ruby/object:Gem::Requirement
|
128
114
|
requirements:
|
129
115
|
- - "~>"
|
130
116
|
- !ruby/object:Gem::Version
|
131
|
-
version: '0
|
117
|
+
version: '1.0'
|
132
118
|
type: :development
|
133
119
|
prerelease: false
|
134
120
|
version_requirements: !ruby/object:Gem::Requirement
|
135
121
|
requirements:
|
136
122
|
- - "~>"
|
137
123
|
- !ruby/object:Gem::Version
|
138
|
-
version: '0
|
124
|
+
version: '1.0'
|
139
125
|
- !ruby/object:Gem::Dependency
|
140
126
|
name: rubocop-performance
|
141
127
|
requirement: !ruby/object:Gem::Requirement
|
@@ -156,14 +142,14 @@ dependencies:
|
|
156
142
|
requirements:
|
157
143
|
- - "~>"
|
158
144
|
- !ruby/object:Gem::Version
|
159
|
-
version:
|
145
|
+
version: 2.1.0
|
160
146
|
type: :development
|
161
147
|
prerelease: false
|
162
148
|
version_requirements: !ruby/object:Gem::Requirement
|
163
149
|
requirements:
|
164
150
|
- - "~>"
|
165
151
|
- !ruby/object:Gem::Version
|
166
|
-
version:
|
152
|
+
version: 2.1.0
|
167
153
|
- !ruby/object:Gem::Dependency
|
168
154
|
name: simplecov
|
169
155
|
requirement: !ruby/object:Gem::Requirement
|
@@ -178,20 +164,6 @@ dependencies:
|
|
178
164
|
- - "~>"
|
179
165
|
- !ruby/object:Gem::Version
|
180
166
|
version: '0.16'
|
181
|
-
- !ruby/object:Gem::Dependency
|
182
|
-
name: sqlite3
|
183
|
-
requirement: !ruby/object:Gem::Requirement
|
184
|
-
requirements:
|
185
|
-
- - "~>"
|
186
|
-
- !ruby/object:Gem::Version
|
187
|
-
version: '1.4'
|
188
|
-
type: :development
|
189
|
-
prerelease: false
|
190
|
-
version_requirements: !ruby/object:Gem::Requirement
|
191
|
-
requirements:
|
192
|
-
- - "~>"
|
193
|
-
- !ruby/object:Gem::Version
|
194
|
-
version: '1.4'
|
195
167
|
- !ruby/object:Gem::Dependency
|
196
168
|
name: vcr
|
197
169
|
requirement: !ruby/object:Gem::Requirement
|
@@ -228,6 +200,7 @@ files:
|
|
228
200
|
- lib/lokalise_rails.rb
|
229
201
|
- lib/lokalise_rails/railtie.rb
|
230
202
|
- lib/lokalise_rails/task_definition/base.rb
|
203
|
+
- lib/lokalise_rails/task_definition/exporter.rb
|
231
204
|
- lib/lokalise_rails/task_definition/importer.rb
|
232
205
|
- lib/lokalise_rails/version.rb
|
233
206
|
- lib/tasks/lokalise_rails_tasks.rake
|
@@ -255,18 +228,22 @@ files:
|
|
255
228
|
- spec/dummy/config/routes.rb
|
256
229
|
- spec/dummy/db/seeds.rb
|
257
230
|
- spec/lib/generators/lokalise_rails/install_generator_spec.rb
|
258
|
-
- spec/lib/lokalise_rails/
|
231
|
+
- spec/lib/lokalise_rails/task_definition/base_spec.rb
|
232
|
+
- spec/lib/lokalise_rails/task_definition/exporter_spec.rb
|
233
|
+
- spec/lib/lokalise_rails/task_definition/importer_spec.rb
|
259
234
|
- spec/lib/lokalise_rails_spec.rb
|
235
|
+
- spec/lib/tasks/export_task_spec.rb
|
260
236
|
- spec/lib/tasks/import_task_spec.rb
|
261
237
|
- spec/spec_helper.rb
|
262
|
-
- spec/support/
|
238
|
+
- spec/support/file_manager.rb
|
263
239
|
- spec/support/rake_utils.rb
|
240
|
+
- spec/support/spec_addons.rb
|
264
241
|
- spec/support/vcr.rb
|
265
242
|
homepage: https://github.com/bodrovis/lokalise_rails
|
266
243
|
licenses:
|
267
244
|
- MIT
|
268
245
|
metadata: {}
|
269
|
-
post_install_message:
|
246
|
+
post_install_message:
|
270
247
|
rdoc_options: []
|
271
248
|
require_paths:
|
272
249
|
- lib
|
@@ -281,8 +258,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
281
258
|
- !ruby/object:Gem::Version
|
282
259
|
version: '0'
|
283
260
|
requirements: []
|
284
|
-
rubygems_version: 3.
|
285
|
-
signing_key:
|
261
|
+
rubygems_version: 3.2.7
|
262
|
+
signing_key:
|
286
263
|
specification_version: 4
|
287
264
|
summary: Lokalise integration for Ruby on Rails
|
288
265
|
test_files:
|
@@ -309,10 +286,14 @@ test_files:
|
|
309
286
|
- spec/dummy/config/routes.rb
|
310
287
|
- spec/dummy/db/seeds.rb
|
311
288
|
- spec/lib/generators/lokalise_rails/install_generator_spec.rb
|
312
|
-
- spec/lib/lokalise_rails/
|
289
|
+
- spec/lib/lokalise_rails/task_definition/base_spec.rb
|
290
|
+
- spec/lib/lokalise_rails/task_definition/exporter_spec.rb
|
291
|
+
- spec/lib/lokalise_rails/task_definition/importer_spec.rb
|
313
292
|
- spec/lib/lokalise_rails_spec.rb
|
293
|
+
- spec/lib/tasks/export_task_spec.rb
|
314
294
|
- spec/lib/tasks/import_task_spec.rb
|
315
295
|
- spec/spec_helper.rb
|
316
|
-
- spec/support/
|
296
|
+
- spec/support/file_manager.rb
|
317
297
|
- spec/support/rake_utils.rb
|
298
|
+
- spec/support/spec_addons.rb
|
318
299
|
- spec/support/vcr.rb
|