Rollup plugin for copying files and folders using the cpy library. Version 2.0.1 is the latest stable release, last updated in 2019. Compatible with Rollup >= 1.0. Provides a simple configuration interface with glob support and verbose logging. Differentiated from other copy plugins (like rollup-plugin-copy) by leveraging the well-maintained cpy package. No active development.
npm install rollup-plugin-cpyVerified import paths — ran on the pinned version, not inferred.
Copies all files from src/static to dist/static, excluding exclude.txt.
Ensure dest directory does not overlap with output dir, or use copy as last plugin.
Make sure Rollup is configured to handle CJS dependencies (e.g., with @rollup/plugin-commonjs).
Pin cpy to v8 in your package.json if issues arise.
Upgrade Node to >=8 and Rollup to >=1.
Use path.posix.join or manually convert backslashes.
Run 'npm install cpy' or add cpy to your devDependencies.
Use: const copy = require('rollup-plugin-cpy').default;Use require() or transpile with Babel/TypeScript.
Upgrade Node to >=12 or remove exports from package.json manually.