Sha256: 768b432f05fe1ca09bb7983de9d8c763ac1c18920716b5d3854fd0da6c0ec12e

Contents?: true

Size: 518 Bytes

Versions: 8

Compression:

Stored size: 518 Bytes

Contents

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}")] }.
                       join("\n")
  end
end

Rake::Task['gettext:find'].enhance ['gettext:store_action_names']

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
foreman-tasks-0.4.0 lib/tasks/gettext.rake
foreman-tasks-0.3.6 lib/tasks/gettext.rake
foreman-tasks-0.3.5 lib/tasks/gettext.rake
foreman-tasks-0.3.4 lib/tasks/gettext.rake
foreman-tasks-0.3.3 lib/tasks/gettext.rake
foreman-tasks-0.3.2 lib/tasks/gettext.rake
foreman-tasks-0.3.1 lib/tasks/gettext.rake
foreman-tasks-0.3.0 lib/tasks/gettext.rake