Sha256: 14ee6a70e9040db9d9fbf2ee191d1224a50813dc7c395d007c5d411fafbd1668
Contents?: true
Size: 709 Bytes
Versions: 15
Compression:
Stored size: 709 Bytes
Contents
gettext_find_task = begin Rake::Task['gettext:find'] rescue nil end if gettext_find_task namespace :gettext do task :store_action_names => :environment do storage_file = "#{locale_path}/action_names.rb" puts "writing action translations to: #{storage_file}" File.write storage_file, "# Autogenerated!\n" + Actions::EntryAction .all_action_names .uniq .map { |n| %[_("#{n}")] } .sort .join("\n") + "\n" end end gettext_find_task.enhance ['gettext:store_action_names'] end
Version data entries
15 entries across 15 versions & 1 rubygems