code: function bundle(entry, output, name) {
    rollup.rollup({
      input: path.resolve(process.cwd(), entry),
      plugins: plugins
    }).then((bundle) => {
      return bundle.generate({
        format: format(),
        name: name,
        sourcemap: true
      })
    }).then(({ code, map}) => {
      return write(path.resolve(process.cwd(), output), code)
    }).then(() => {
      var source = fs.readFileSync(path.resolve(process.cwd(), output), 'utf-8', (err) => { throw err })
      var compilerFlags = {
        jsCode: [{ src: source }],
        compilationLevel: 'ADVANCED',
        languageOut: 'ECMASCRIPT5',
        createSourceMap: true
      }
      var result = compiler(compilerFlags)
      var minPath = 'bundle/' + output.split('/').pop().split('.')[0] + '.min.js'
      var sourcePath = minPath + '.map'
      // write min.js and min.js.map
      fs.writeFileSync(minPath, result.compiledCode, 'utf-8', (err) => { throw err })
      fs.writeFileSync(sourcePath, result.sourceMap, 'utf-8', (err) => { throw err })
      console.info(chalk.red(minPath) + ' ' + chalk.green(getSize(result.compiledCode)))
    }).catch((err) => {
      console.error(err)
    })
  }
docs: prod bundle file ( min.js sourcemap )
  
  @param { String } entry
  @param { String } output
  @param { String } name