tolk 1.9.3 → 2.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/app/controllers/tolk/application_controller.rb +1 -1
- data/app/controllers/tolk/locales_controller.rb +3 -2
- data/app/controllers/tolk/searches_controller.rb +1 -1
- data/app/models/tolk/translation.rb +1 -1
- data/lib/tolk/config.rb +5 -0
- data/lib/tolk/version.rb +1 -1
- metadata +4 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 90462539c407ff422fdf13f5fbac68457c8c2807
|
4
|
+
data.tar.gz: cb5c5bc05f5a99a785c7d75261de04aceddf4d80
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ab4f1e9ad6b85a8baef406004c20814397eaf725c6271970043929a08c24a10c8de6dcf1d265673db61d1ea5a97f9c6ba0fe61eb110465ea1a3d94fc43fb7545
|
7
|
+
data.tar.gz: 43907b282e5a3eda7f190b9eb7d0bab377ebb3b6bf166fcddcfbdd66b1d1eb38a50271b0475035eebe4fc76101c03232392898901b62d001e44793961a94ae17
|
@@ -1,7 +1,7 @@
|
|
1
1
|
module Tolk
|
2
2
|
class LocalesController < Tolk::ApplicationController
|
3
|
-
|
4
|
-
|
3
|
+
before_action :find_locale, :only => [:show, :all, :update, :updated]
|
4
|
+
before_action :ensure_no_primary_locale, :only => [:all, :update, :show, :updated]
|
5
5
|
|
6
6
|
def index
|
7
7
|
@locales = Tolk::Locale.secondary_locales.sort_by(&:language_name)
|
@@ -46,6 +46,7 @@ module Tolk
|
|
46
46
|
def dump_all
|
47
47
|
Tolk::Locale.dump_all
|
48
48
|
I18n.reload!
|
49
|
+
I18n::JS.export if defined? I18n::JS
|
49
50
|
redirect_to request.referrer
|
50
51
|
end
|
51
52
|
|
data/lib/tolk/config.rb
CHANGED
@@ -20,9 +20,14 @@ module Tolk
|
|
20
20
|
# reject files of type xxx.en.yml when syncing locales
|
21
21
|
attr_accessor :block_xxx_en_yml_locale_files
|
22
22
|
|
23
|
+
# strip translation texts automatically
|
24
|
+
attr_accessor :strip_texts
|
25
|
+
|
23
26
|
def reset
|
24
27
|
@exclude_gems_token = false
|
25
28
|
|
29
|
+
@strip_texts = true
|
30
|
+
|
26
31
|
@block_xxx_en_yml_locale_files = true # keep compat with older versions
|
27
32
|
|
28
33
|
@dump_path = Proc.new { "#{Rails.application.root}/config/locales" }
|
data/lib/tolk/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tolk
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 2.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- David Heinemeier Hansson
|
@@ -12,7 +12,7 @@ authors:
|
|
12
12
|
autorequire:
|
13
13
|
bindir: bin
|
14
14
|
cert_chain: []
|
15
|
-
date:
|
15
|
+
date: 2016-10-21 00:00:00.000000000 Z
|
16
16
|
dependencies:
|
17
17
|
- !ruby/object:Gem::Dependency
|
18
18
|
name: rails
|
@@ -21,9 +21,6 @@ dependencies:
|
|
21
21
|
- - ">="
|
22
22
|
- !ruby/object:Gem::Version
|
23
23
|
version: '4.0'
|
24
|
-
- - "<"
|
25
|
-
- !ruby/object:Gem::Version
|
26
|
-
version: '4.3'
|
27
24
|
type: :runtime
|
28
25
|
prerelease: false
|
29
26
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -31,9 +28,6 @@ dependencies:
|
|
31
28
|
- - ">="
|
32
29
|
- !ruby/object:Gem::Version
|
33
30
|
version: '4.0'
|
34
|
-
- - "<"
|
35
|
-
- !ruby/object:Gem::Version
|
36
|
-
version: '4.3'
|
37
31
|
- !ruby/object:Gem::Dependency
|
38
32
|
name: safe_yaml
|
39
33
|
requirement: !ruby/object:Gem::Requirement
|
@@ -177,7 +171,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
177
171
|
requirements:
|
178
172
|
- - ">="
|
179
173
|
- !ruby/object:Gem::Version
|
180
|
-
version:
|
174
|
+
version: 2.0.0
|
181
175
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
182
176
|
requirements:
|
183
177
|
- - ">="
|
@@ -185,7 +179,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
185
179
|
version: '0'
|
186
180
|
requirements: []
|
187
181
|
rubyforge_project:
|
188
|
-
rubygems_version: 2.4.
|
182
|
+
rubygems_version: 2.4.5
|
189
183
|
signing_key:
|
190
184
|
specification_version: 4
|
191
185
|
summary: Rails engine providing web interface for managing i18n yaml files
|