bun-n2b

Migrate Node.js projects to Bun-native runtime with n2b CLI.

Updated Apr 17, 2026
One-click install
npx skills add https://github.com/aphrody-code/n2b --skill bun-n2b
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: bun-n2b
Source: https://github.com/aphrody-code/n2b/tree/main/skills/n2b
Command: npx skills add https://github.com/aphrody-code/n2b --skill bun-n2b

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

It detects and fixes (or guides you through) Node.js-to-Bun incompatibilities so your project runs correctly on Bun without manual, error-prone rewrites.

Core Features & Use Cases

  • Node tooling & import/script migration: Rewrites npm/npx/pnpm/yarn and related workflow/shell/Docker usage to bun/bunx, and updates Node built-in imports to use proper Bun/node: prefixes.
  • API and idiom modernization: Flags redundant dependencies that Bun can replace, and migrates common Node patterns (like fs read/write and related idioms) toward Bun-native equivalents where safe.
  • Audit-to-fix workflow with guardrails: Produces multiple report formats (including JSON/SARIF) and applies scoped safe fixes with optional aggressive migration steps plus post-fix build/test gating.

Quick Start

Run the bun-n2b skill on your project directory to audit Node patterns and automatically apply safe Bun-native rewrites for scripts and CI-related areas.

Frequently Asked Questions about bun-n2b

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I migrate a Node.js project to Bun automatically?

To migrate a Node.js project to Bun, you can run an automated audit that detects incompatible tooling, rewrites npm scripts to bun, and updates Node built-in imports to use proper node: prefixes across your repository.

What does Node to Bun migration change in CI workflows and Dockerfiles?

Node to Bun migration rewrites package managers like npm, npx, pnpm, and yarn to bun and bunx equivalents, specifically targeting and updating shell commands and Dockerfile instructions to use the Bun runtime.

Do I need to manually rewrite Node fs read/write calls for Bun compatibility?

You do not need to manually rewrite Node fs calls, as the migration process safely flags redundant dependencies and modernizes common Node coding idioms toward Bun-native equivalents.

How do I verify safe fixes when migrating to the Bun runtime?

To verify safe fixes during Bun migration, you use controlled scopes with post-migration build and lint gating, while generating JSON or SARIF reports to review detected incompatibilities before applying aggressive changes.

Does migrating to Bun break existing package.json scripts?

Migrating to Bun updates package.json scripts by rewriting Node tooling commands to Bun equivalents, applying scoped safe fixes with optional aggressive migration steps to ensure CI workflows and builds pass post-fix verification.