Files
cli/rollup.config.js
Daniel Fugere d91ee1965f Adding contract command (#1)
* chore: added contract command

* chore: added make check and make format

* chore: getting the generate command to work

* chore: added the --file option to the generate command

* fix: got tests passing

* chore: got rid of deprecation warnings

* chore: added ci check

* Bumping requirement to v18

* Use stdout instead of stderr

* Reworked shebang to disable experimental warnings

* Made logging less verbose

* Removed v16 testing

* Inverted logging logic to debug by default

---------

Co-authored-by: Aaron Cox <aaron@greymass.com>
2023-08-28 16:59:18 -07:00

28 lines
695 B
JavaScript

import typescript from '@rollup/plugin-typescript'
import cleanup from 'rollup-plugin-cleanup'
import json from '@rollup/plugin-json'
import pkg from './package.json'
const external = ['fs', ...Object.keys(pkg.dependencies)]
// Add shebang + disable experimental fetch warning
const banner = `
#!/usr/bin/env node
process.removeAllListeners('warning')
`.trim()
/** @type {import('rollup').RollupOptions} */
export default {
input: 'src/index.ts',
output: {
banner,
file: pkg.main,
format: 'cjs',
sourcemap: true,
exports: 'named',
},
plugins: [typescript({target: 'es6'}), json(), cleanup({extensions: ['js', 'ts']})],
external,
}