Sha256: b4f9575d365ea088d44137967e14b8c61273bffc5aaaeebbb1d2bbe6d8b63bfa

Contents?: true

Size: 555 Bytes

Versions: 6

Compression:

Stored size: 555 Bytes

Contents

# desc "Explaining what the task does"
# task :awesome_translations do
#   # Task goes here
# end

namespace :awesome_translations do
  task "install" => :environment do
    yml_root = Rails.root.join("config/locales/awesome_translations")

    dirs = [
      yml_root,
      "#{yml_root}/helpers",
      "#{yml_root}/models",
      "#{yml_root}/views",
      "#{yml_root}/controllers"
    ]

    dirs.each do |dir|
      unless File.exist?(dir)
        puts "[AwesomeTranslations] Creating dir: #{dir}"
        Dir.mkdir(dir)
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
awesome_translations-0.0.66 lib/tasks/awesome_translations_tasks.rake
awesome_translations-0.0.65 lib/tasks/awesome_translations_tasks.rake
awesome_translations-0.0.64 lib/tasks/awesome_translations_tasks.rake
awesome_translations-0.0.63 lib/tasks/awesome_translations_tasks.rake
awesome_translations-0.0.62 lib/tasks/awesome_translations_tasks.rake
awesome_translations-0.0.61 lib/tasks/awesome_translations_tasks.rake