rails_translation_manager 1.1.0 → 1.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0b6a096ee29746cead2529ea0cb83660c0e0217b710e085790969f203f246871
4
- data.tar.gz: 3c13cb54190c17f1382246827c120cf928e7763a9de4b4724ec36ffe6005fc62
3
+ metadata.gz: 234b68e06027a3335015a5818993014afea669efe42729d87f4de40efd4dc487
4
+ data.tar.gz: 54a16b4f583813415a6801c62fda5eb9ee603e84bf65206700c0bc33b295b238
5
5
  SHA512:
6
- metadata.gz: 37abc2c32de6245dc3d1cd57da56f14ab3c68f88f9b3802a65735d3c36c02984f823d45ff177729daad6b2234929d03535ca28239a4188889a14be60f35875df
7
- data.tar.gz: 73f08794d826203ba2be01695751d742bd7a546dee1bf9f8946c98cf57350a48651addd5eef53cfcd9b23303900d6efe0dcd41fb0ae81d67ba060ed851b5061a
6
+ metadata.gz: 2ab59ec749b2827c011728fe5711c850099d379d9089c2d73fc112def0f02c994b58ed646f42fe106c2d15d56cd5aaad1db636d7afe1504740109b57baca3c2f
7
+ data.tar.gz: 9313168a8704e4985ae4a57d89fb6bc8dc47a5ac2f1ae6cdd73686aeec0fe657617776620db6a65c0c45b708ec2de06dc390d546509198a836b6ff7a14212ca3
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## 1.1.1
2
+
3
+ Fix Rails Translation Manager / Rails naming clash for class. https://github.com/alphagov/rails_translation_manager/pull/26
4
+
1
5
  ## 1.1.0
2
6
 
3
7
  Allow multiple files per language to be imported. https://github.com/alphagov/rails_translation_manager/pull/20
@@ -1,5 +1,4 @@
1
- class TranslationHelper
2
-
1
+ class RailsTranslationManager::I18nTasksOptionParser
3
2
  def initialize(task_options, locale)
4
3
  @task_options = task_options
5
4
  @locale = locale
@@ -1,3 +1,3 @@
1
1
  module RailsTranslationManager
2
- VERSION = "1.1.0"
2
+ VERSION = "1.1.1"
3
3
  end
@@ -1,6 +1,6 @@
1
- require "rails_translation_manager"
2
1
  require "i18n/tasks/cli"
3
- require_relative "../tasks/translation_helper"
2
+ require_relative "../rails_translation_manager"
3
+ require_relative "../rails_translation_manager/i18n_tasks_option_parser"
4
4
 
5
5
  namespace :translation do
6
6
 
@@ -67,13 +67,21 @@ namespace :translation do
67
67
 
68
68
  desc "Add missing translations"
69
69
  task(:add_missing, [:locale] => [:environment]) do |t, args|
70
- I18n::Tasks::CLI.start(TranslationHelper.new(["add-missing", "--nil-value"], args[:locale]).with_optional_locale)
70
+ option_parser = RailsTranslationManager::I18nTasksOptionParser.new(
71
+ ["add-missing", "--nil-value"], args[:locale]
72
+ ).with_optional_locale
73
+
74
+ I18n::Tasks::CLI.start(option_parser)
71
75
  RailsTranslationManager::Cleaner.new(Rails.root.join("config", "locales")).clean
72
76
  end
73
77
 
74
78
  desc "Normalize translations"
75
79
  task(:normalize, [:locale] => [:environment]) do |t, args|
76
- I18n::Tasks::CLI.start(TranslationHelper.new(["normalize"], args[:locale]).with_optional_locale)
80
+ option_parser = RailsTranslationManager::I18nTasksOptionParser.new(
81
+ ["normalize"], args[:locale]
82
+ ).with_optional_locale
83
+
84
+ I18n::Tasks::CLI.start(option_parser)
77
85
  RailsTranslationManager::Cleaner.new(Rails.root.join("config", "locales")).clean
78
86
  end
79
87
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rails_translation_manager
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Edd Sowden
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-11-03 00:00:00.000000000 Z
11
+ date: 2021-11-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails-i18n
@@ -143,6 +143,7 @@ files:
143
143
  - lib/rails_translation_manager.rb
144
144
  - lib/rails_translation_manager/cleaner.rb
145
145
  - lib/rails_translation_manager/exporter.rb
146
+ - lib/rails_translation_manager/i18n_tasks_option_parser.rb
146
147
  - lib/rails_translation_manager/importer.rb
147
148
  - lib/rails_translation_manager/locale_checker.rb
148
149
  - lib/rails_translation_manager/locale_checker/all_locales.rb
@@ -156,7 +157,6 @@ files:
156
157
  - lib/rails_translation_manager/version.rb
157
158
  - lib/rails_translation_manager/yaml_writer.rb
158
159
  - lib/tasks/translation.rake
159
- - lib/tasks/translation_helper.rb
160
160
  - rails_translation_manager.gemspec
161
161
  - spec/locales/cleaner/clean.yml
162
162
  - spec/locales/cleaner/with_whitespace.yml