code: function (fileName, outFileName, config, moduleName, pluginCollector) {
              var parts = (config.optimize + "").split('.'),
                  optimizerName = parts[0],
                  keepLines = parts[1] === 'keepLines',
                  licenseContents = '',
                  fileContents, optFunc, match, comment;
  
              fileContents = file.readFile(fileName);
  
              //Apply pragmas/namespace renaming
              fileContents = pragma.process(fileName, fileContents, config, 'OnSave', pluginCollector);
  
              //Optimize the JS files if asked.
              if (optimizerName && optimizerName !== 'none') {
                  optFunc = envOptimize[optimizerName] || optimize.optimizers[optimizerName];
                  if (!optFunc) {
                      throw new Error('optimizer with name of "' +
                                      optimizerName +
                                      '" not found for this environment');
                  }
  
                  if (config.preserveLicenseComments) {
                      //Pull out any license comments for prepending after optimization.
                      optimize.licenseCommentRegExp.lastIndex = 0;
                      while ((match = optimize.licenseCommentRegExp.exec(fileContents))) {
                          comment = match[0];
                          //Only keep the comments if they are license comments.
                          if (comment.indexOf('@license') !== -1 ||
                              comment.indexOf('/*!') === 0) {
                              licenseContents += comment + '\n';
                          }
                      }
                  }
  
                  fileContents = licenseContents + optFunc(fileName, fileContents, keepLines,
                                          config[optimizerName]);
              }
  
              file.saveUtf8File(outFileName, fileContents);
          }
docs: Optimizes a file that contains JavaScript content. Optionally collects
  plugin resources mentioned in a file, and then passes the content
  through an minifier if one is specified via config.optimize.
  
  @param {String} fileName the name of the file to optimize
  @param {String} outFileName the name of the file to use for the
  saved optimized content.
  @param {Object} config the build config object.
  @param {String} [moduleName] the module name to use for the file.
  Used for plugin resource collection.
  @param {Array} [pluginCollector] storage for any plugin resources
  found.