bun

bun is a cursor rule for Cursor from hiromaily/go-crypto-wallet. It costs 0 tokens per session (565 once invoked), scanned A, original, MIT.

Rules for projects that use Bun, a JavaScript runtime and package manager, instead of Node.js tools. They map common npm commands to their Bun equivalents.

In plain words
What is it for?
Use them when installing packages, running scripts, testing, or managing dependencies in a Bun project.
Why use it?
Mixing npm and Bun can create inconsistent lock files, dependencies, and project setup. These rules keep package management and scripts consistent.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit Use them when installing packages, running scripts, testing, or managing dependencies in a Bun project.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/hiromaily/go-crypto-wallet/bun
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/hiromaily/go-crypto-wallet

Made for: Cursor.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for bun

README.md
[![agentmods](https://agentmods.dev/badge/rules/hiromaily/go-crypto-wallet/bun/github.svg)](https://agentmods.dev/rules/hiromaily/go-crypto-wallet/bun)
Your own site
<a href="https://agentmods.dev/rules/hiromaily/go-crypto-wallet/bun"><img src="https://agentmods.dev/badge/rules/hiromaily/go-crypto-wallet/bun/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for bun

Your own site · 80×15
<a href="https://agentmods.dev/rules/hiromaily/go-crypto-wallet/bun"><img src="https://agentmods.dev/badge/rules/hiromaily/go-crypto-wallet/bun.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 565 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.00565
Opus 5 $0.00000 $0.00282
Sonnet 5 $0.00000 $0.00113
Haiku 4.5 $0.00000 $0.00056

Measured 7d ago against content hash 06b0aca2b95c, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

bun scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.cursor/rules/apps/bun.mdc · 111 lines

What it actually says

Bun Runtime Rules

Overview

Rules for projects using Bun runtime instead of Node.js.

Critical Rule: Use Bun Commands Only

DO NOT use npm/npx commands in Bun projects.

Wrong (npm/npx) Correct (bun/bunx)
npm install bun install
npm run <script> bun run <script>
npm test bun test
npm ci bun install --frozen-lockfile
npx <package> bunx <package>
npm init bun init
npm add <pkg> bun add <pkg>
npm remove <pkg> bun remove <pkg>

Why This Matters

  1. Lock file mismatch: npm creates package-lock.json, Bun uses bun.lock
  2. Dependency resolution: Different algorithms may cause inconsistencies
  3. Performance: Bun is significantly faster
  4. Project consistency: Keep tooling consistent across the team

Command Reference

Package Management

# Install all dependencies
bun install

# Add a dependency
bun add <package>
bun add <package> -D  # dev dependency

# Remove a dependency
bun remove <package>

# Update dependencies
bun update

Running Scripts

# Run a script from package.json
bun run <script>

# Run TypeScript directly
bun run src/index.ts

# Run with watch mode
bun --watch src/index.ts

Executing Packages

# Execute a package binary (like npx)
bunx <package>

# Examples
bunx tsc --noEmit
bunx biome check .

Applicable Directories

This rule applies to:

  • apps/xrpl-grpc-server/ - Uses Bun runtime

Verification

Check if a project uses Bun:

  1. Look for bun.lock file (not package-lock.json)

  2. Check engines field in package.json:

    "engines": {
      "bun": ">=1.3.6"
    }
    

Common Mistakes to Avoid

# WRONG - Do not use these
npm install
npm run dev
npx biome check .

# CORRECT - Use these instead
bun install
bun run dev
bunx biome check .
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago First seen · 111 lines · 0 tokens per session scan A 06b0aca2b95c

Subscribe to this mod's changes

bun is a cursor rule published in the GitHub repository hiromaily/go-crypto-wallet (127 stars, last pushed 4mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 565 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-01.