summaryrefslogtreecommitdiffstats
path: root/lib/tasks/locales.rake
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2012-07-05 12:52:28 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2012-07-05 12:52:28 +0000
commitcc2ee90f9797d3657d24589774374ba1d9867b8f (patch)
tree3be98c0a860cdd95049331f8cd4072036f3fb71a /lib/tasks/locales.rake
parent1eebd030ca7a516c2c69d04e7b94d63085c7e48e (diff)
downloadredmine-cc2ee90f9797d3657d24589774374ba1d9867b8f.tar.gz
redmine-cc2ee90f9797d3657d24589774374ba1d9867b8f.zip
sort files in locales:check_interpolation and locales:check_parsing_by_psych rake tasks
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9915 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'lib/tasks/locales.rake')
-rw-r--r--lib/tasks/locales.rake5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/tasks/locales.rake b/lib/tasks/locales.rake
index 66801f011..573e0eb88 100644
--- a/lib/tasks/locales.rake
+++ b/lib/tasks/locales.rake
@@ -41,7 +41,8 @@ namespace :locales do
dir = ENV['DIR'] || './config/locales'
en_strings = YAML.load(File.read(File.join(dir,'en.yml')))['en']
files = Dir.glob(File.join(dir,'*.{yaml,yml}'))
- files.each do |file|
+ files.sort.each do |file|
+ puts "parsing #{file}..."
file_strings = YAML.load(File.read(file))
file_strings = file_strings[file_strings.keys.first]
@@ -129,7 +130,7 @@ END_DESC
parser = Psych::Parser.new
dir = ENV['DIR'] || './config/locales'
files = Dir.glob(File.join(dir,'*.yml'))
- files.each do |filename|
+ files.sort.each do |filename|
next if File.directory? filename
puts "parsing #{filename}..."
begin