summaryrefslogtreecommitdiff
path: root/lib/tasks
diff options
context:
space:
mode:
authorelijah <elijah@riseup.net>2015-08-03 22:26:53 -0700
committerelijah <elijah@riseup.net>2015-08-03 22:26:53 -0700
commita9f336cdf784bc6f0dd0062b8f7253ed57799da7 (patch)
tree5b50189662f6f66f649ca78c1dd86691c5091c8b /lib/tasks
parentba3e2451b8bce4dad34e8e28855d16d8c26c118b (diff)
updated en_US.yml
Diffstat (limited to 'lib/tasks')
-rw-r--r--lib/tasks/i18n.rake30
1 files changed, 16 insertions, 14 deletions
diff --git a/lib/tasks/i18n.rake b/lib/tasks/i18n.rake
index 896f67e..6ffbb23 100644
--- a/lib/tasks/i18n.rake
+++ b/lib/tasks/i18n.rake
@@ -26,24 +26,26 @@ namespace :i18n do
#
desc "combine config/locales/*.en.yml to lib/en_US.yml"
task :bundle do
- en_yml = File.join(Rails.root, 'lib', 'en_US.yml')
- File.open(en_yml, 'w') do |output|
- output.write("en_US:\n\n"+
- "### Do NOT edit this file directly, as all changes will be overwritten by `rake i18n:bundle`\n"+
- "### Instead, make changes in the appropriate file in config/locales.\n"+
- "### Source strings in transifex are automatically updated from this file (via github url)")
+ Dir.chdir(Rails.root) do
+ en_yml = 'lib/en_US.yml'
+ File.open(en_yml, 'w') do |output|
+ output.write("en_US:\n\n"+
+ "### Do NOT edit this file directly, as all changes will be overwritten by `rake i18n:bundle`\n"+
+ "### Instead, make changes in the appropriate file in config/locales.\n"+
+ "### Source strings in transifex are automatically updated from this file (via github url)")
- Dir.chdir('config/locales/') do
- Dir.glob('*.en.yml').sort.each do |file|
- process_locale_file(output, file)
+ Dir.chdir('config/locales/en') do
+ Dir.glob('*.en.yml').sort.each do |file|
+ process_locale_file(output, file)
+ end
end
- end
- Dir.chdir('engines/') do
- Dir.glob('*/config/locales/en.yml').sort.each do |file|
- process_locale_file(output, file)
+ Dir.chdir('engines') do
+ Dir.glob('*/config/locales/en.yml').sort.each do |file|
+ process_locale_file(output, file)
+ end
end
+ puts "You can now find the bundled locale yml in: #{en_yml}"
end
- puts "You can now find the bundled locale yml in: #{en_yml}"
end
end