 
       @[currentLocale].files =  [
         expand: true
-        cwd: '<%= path.source.layouts %>/'
-        src: ['{,**/}*.{nj,html}', '!{,**/}_*.{nj,html}']
-        dest: '<%= path.build.root %>/' + localeDir
-        ext: '.html'
+        cwd: taskConfig.files.cwd + '/'
+        src: taskConfig.files.src
+        dest: taskConfig.files.dest + '/' + localeDir
+        ext: taskConfig.files.ext
         rename: (dest, src) =>
-          src = humanReadableUrl(src)
+          if taskConfig.humanReadableUrls.enabled
+            src = humanReadableUrl(src)
           path.join(dest, src)
       ]
 

  marked       = require('marked')
  markdown     = require('nunjucks-markdown')
  urlify       = require('urlify').create({
    addEToUmlauts: true
    szToSs: true
    spaces: '-'
    toLower: true
    nonPrintable: '-'
    trim: true
    failureOutput: 'non-printable-url'
  })

  locales       = grunt.config('data.site.locales')
  baseLocale    = grunt.config('data.site.baseLocale')

  defaultDomain = 'messages'

  buildDir      = grunt.config('path.build.root')
  layoutsDir    = grunt.config('path.source.layouts')
  localesDir    = grunt.config('path.source.locales')

  ###*
   * Replace placeholders with provided values via `sprintf` or `vsprintf`. Function will choice

###

module.exports = (grunt) ->
  taskConfig =
    autoescape          : false
    data                : '<%= data %>'
    path:
      build             : grunt.config('path.build.root')
      layouts           : grunt.config('path.source.layouts')
      nunjucksEnv       : grunt.config('path.source.layouts')
      locales           : grunt.config('path.source.locales')
    files:
      cwd               : '<%= path.source.layouts %>/'
      src               : ['{,**/}*.{nj,html}', '!{,**/}_*.{nj,html}']
      dest              : '<%= path.build.root %>/'
      ext               : '.html'
    humanReadableUrls:
      enabled           : true
      exclude           : /^(index|\d{3})$/
    i18n:
      locales           : grunt.config('data.site.locales')
      baseLocale        : grunt.config('data.site.baseLocale')
      defaultDomain     : 'messages'
    numberDefaultFormat : '0,0[.]00'
    urlify:
      addEToUmlauts     : true
      szToSs            : true
      spaces            : '-'
      toLower           : true
      nonPrintable      : '-'
      trim              : true
      failureOutput     : 'non-printable-url'


  _            = require('lodash')
  path         = require('path')
  numbro       = require('numbro')
