Registry / devops / rollup-plugin-execute

rollup-plugin-execute

JSON →
library1.1.1jsnpmunverified

A Rollup plugin that executes shell commands sequentially after the bundle is generated. Version 1.1.1 is stable with no recent releases; it accepts a command string or array of commands and runs them in order using child_process.execSync. Lightweight and zero-dependency, ideal for post-build tasks like copying files or opening a browser. Alternative to rollup-plugin-shell, but simpler with no cross-platform handling.

npm install rollup-plugin-execute
INSTALL
IMPORT
SIG · ROLLUP-PLUGIN-EXEC
R
rollup-plugin-execute
devopsjavascriptv1.1.1
Install
Import
Disk
Pass rate
0/ 6
Env Coverage0 / 6
glibc
1822
musl
1822
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18223 runs
build_error
glibc
node 18223 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

execute
import execute from 'rollup-plugin-execute'
const execute = require('rollup-plugin-execute')
Package is ESM-only; CommonJS require will fail.

Minimal Rollup config that writes a status file after bundle generation using execute().

// rollup.config.js import execute from 'rollup-plugin-execute' export default { input: 'src/index.js', output: { file: 'dist/bundle.js', format: 'esm' }, plugins: [ execute('echo "Build complete" > dist/status.txt') ] }
Debug
Known issues
gotchaexecute() runs synchronously using execSync, blocking the build until commands finish.
fix
Keep commands quick to avoid slowing down the build; consider async alternatives for long tasks.
affects: >=1.0.0
Errors
Common errors & fixes
Error [ERR_REQUIRE_ESM]: require() of ES Module not supported
rollup-plugin-execute is ESM-only and cannot be required with CommonJS.
fix
Use import statement or set type: 'module' in package.json.
Upgrade
Version history
1.1.1latest on npm
Audit
Dependencies

No dependency data recorded yet.

Agent activity
6 hits · last 30 days
node
4
Resources
rollup-plugin-execute — npm install rollup-plugin-execute · libregistry