code: function (template) {
      var pattern = _.template(template)(fileReplace);
      pattern = pattern.replace(/\//g, '\\/');
      pattern = pattern.replace(/\s+/g, '\\s*');
      pattern = '\\s*' + pattern + '\\s*';
      return new RegExp(pattern);
  }
docs: Convert the template into a RegExp that can capture the file name.
  @param {string} template
  @returns {RegExp} A regular expression that can capture the file name.