/*官网开发配置*/
var path = require('path');
var settings = require('../settings');
var server_util = require('fis3-command-server/lib/util');
var _ = require('../../lib/util');
module.exports = function (hoo, root, media) {
  hoo.set('project.files', '**.png');
  // 设置占位符
  hoo.media(media).match('**', {
    useHash: false
  })
    .match('**.png', {
      optimizer: hoo.plugin('png-compressor', {
        // pngcrush or pngquant
        // default is pngcrush
        type: 'pngquant'
      }),
      release:'$0'
    })
    .match('**', {
      deploy: hoo.plugin('local-deliver', {
        to: path.join(media === 'pngc'?settings.sourceDir:settings.wwwSourceDir, root)
      })
    });
};
