@gobing-ai/spur

中文文档
0.4.35发布于 2026/11/15Apache-2.0TypeScriptES Module构建来源已验证近 30 天下载 5660

Spur CLI — local-first harness for mainstream coding agents: constraint checking, workflow orchestration, agent health, and history analytics. Bun-native; exposes the spur command.

原始使用文档
文档目录9 节
  1. Install
  2. If you have Bun ( bun >= 1.3.0 ) — recommended
  3. If you don't have Bun — standalone binary
  4. Package layout (what ships)
  5. First run
  6. Usage
  7. Extending the Spur Board
  8. Documentation
  9. License

@gobing-ai/spur

The spur command — a local-first harness for mainstream coding agents (Claude Code, Codex, Gemini CLI, pi, omp, OpenCode, Antigravity, OpenClaw, Hermes, Grok). Spur is not a coding agent; it wraps the agents you already have with constraint checking, workflow orchestration, agent health checks, and conversation-history analytics.

Install

Pick the path that matches your setup. Both give you a global spur command and seed the default config into ~/.config/spur/ on first run.

The npm package ships a Bun bundle and runs under the Bun runtime you already have.

# Install globally → use the `spur` command everywhere
bun install -g @gobing-ai/spur
spur --help

# …or run ad-hoc with no install
bunx @gobing-ai/spur --help

Install the sp plugin to your coding agents

The npm package ships the sp plugin and its marketplace manifest alongside the CLI. Install it into your supported coding agents without cloning this repository:

# point superskill at the installed @gobing-ai/spur package root
superskill install sp --marketplace $(npm root -g)/@gobing-ai/spur

(With Bun: bun install -g @gobing-ai/spur; the package root is $(npm root -g)/@gobing-ai/spur or $(bun pm bin -g)/../lib/node_modules/@gobing-ai/spur.) This registers the marketplace and installs the sp plugin to Claude Code, Codex, Gemini CLI, pi, omp, OpenCode, Antigravity, etc.

If you don't have Bun — standalone binary

A self-contained executable (Bun embedded) for macOS and Linux. No runtime to install.

# One-liner: downloads the binary, puts it on PATH, seeds config
curl -fsSL https://raw.githubusercontent.com/gobing-ai/spur/main/scripts/install.sh | sh
spur --help

The installer drops spur into ~/.local/bin by default. Override the target with SPUR_INSTALL, or pin a release with SPUR_VERSION:

SPUR_INSTALL=/usr/local/bin SPUR_VERSION='@gobing-ai/spur-v0.1.7' \
  sh -c "$(curl -fsSL https://raw.githubusercontent.com/gobing-ai/spur/main/scripts/install.sh)"

If ~/.local/bin isn't already on your PATH, add it (e.g. export PATH="$HOME/.local/bin:$PATH" in your shell profile). Supported targets: darwin-arm64, darwin-x64, linux-arm64, linux-x64. Windows: use the Bun path under WSL.

Verification. The installer downloads to a temp file, checks it against the release's SHA256SUMS, and only then atomically replaces spur. A failed download, a checksum mismatch, or a missing SHA256SUMS leaves an existing install untouched and exits non-zero. SPUR_RELEASE_URL overrides the download base URL (a mirror, or a file:// directory in tests).

The checksum is a code-execution boundary, not just an integrity check: having verified the download, the installer runs it (spur init), so a release whose SHA256SUMS cannot be verified is a release you cannot safely install. SPUR_SKIP_VERIFY=1 is the single explicit bypass and prints a warning — keep it for local or air-gapped installs, and pipe the script into sh only from a source you trust.

Releasing standalone binaries. Run bun run build:binaries in apps/cli, then upload all of dist/cli/spur-* and dist/cli/SHA256SUMS to the GitHub Release for the tag. A release without SHA256SUMS makes the installer fail by default.

Package layout (what ships)

The published tarball is a self-contained Bun bundle plus static assets:

PathPurpose
spur.jsCLI entry (bin.spur)
config/Default rules, workflows, tasks, templates, plugins (ADR-015 SSOT)
web/Spur Board SPA served by spur serve
schemas/JSON Schema for editor/CI validation

spur init copies the full config/ tree into the project .spur/ directory (and seeds ~/.config/spur/ globally on first run). spur serve resolves board assets from package web/.

First run

spur init     # scaffold .spur/ from bundled config/ + seed ~/.config/spur/ — idempotent, never clobbers
spur serve    # local board at http://localhost:3000/board (uses package web/)

The standalone installer runs spur init for you; the Bun install does it on your first spur init.

Usage

spur init                                  # scaffold .spur/ + seed global rules
spur serve --port 5678                     # start API + Spur Board
spur rule run --preset recommended-pre-check   # evaluate constraint rules
spur workflow run <workflow.yaml>          # run an FSM workflow
spur agent run "<prompt>" --agent auto     # execute a prompt via a coding agent
spur agent doctor                          # check agent readiness
spur history import --source claude --root <path>
spur history analyze
spur status

Every command supports --json for machine-readable output.

Extending the Spur Board

A project can add its own Board modules — a compiled React tool or an embedded URL app — without editing this package. An installed Board reads them from a fresh project's .spur/config.yaml:

bootstrap:
  modules:
    - id: team-board
      name: Team board
      icon: "🧭"
      type: react
      directory: board/team-board/dist
      entry: index.js
      styles: [index.css]
    - id: docs
      name: Documentation
      icon: "📚"
      type: iframe
      url: https://docs.example.test/

spur init seeds modules: [] (built-ins only); change selection with a config edit, then restart spur serve and reload. The full authoring contract — the declaration union, the @gobing-ai/spur/board type export, the Vite library setup and the frame/trust limits — is in the downstream Board modules design.

Documentation

Full docs, architecture, and the complete command surface live in the Spur repository.

License

Apache-2.0 © Robin Min

版本与发布记录

@gobing-ai/spur 共发布 142 个版本,首次发布于 2026/06/10;过去 12 个月发布了 142 个版本。最新版本附带 npm provenance 构建来源证明,可追溯到公开的 CI 构建记录。

版本发布日期距今
0.4.35latest2026/11/151 天前
0.4.342026/11/152 天前
0.4.332026/11/133 天前
0.4.312026/11/115 天前
0.4.302026/11/106 天前
0.4.292026/11/097 天前

关于 @gobing-ai/spur 的常见问题

@gobing-ai/spur 是什么?

Spur CLI — local-first harness for mainstream coding agents: constraint checking, workflow orchestration, agent health, and history analytics. Bun-native; exposes the spur command.

如何安装 @gobing-ai/spur?

在项目目录运行 npm install @gobing-ai/spur,或使用 pnpm add / yarn add / bun add。它还提供命令行工具 spur,可以用 npx spur 直接运行。

@gobing-ai/spur 支持 TypeScript 吗?

支持。包内自带 TypeScript 类型声明(package.json 声明了 types 入口),安装后即可获得类型提示,无需再安装 @types 包。

@gobing-ai/spur 支持 ESM 还是 CommonJS?

以 ES Module 形式发布,推荐使用 import 引入。在 CommonJS 项目中,Node.js 20.19+ / 22.12+ 可以直接 require() 不含顶层 await 的 ES Module,更早的版本需要改用动态 import()。

@gobing-ai/spur 可以商用吗?

@gobing-ai/spur 使用 Apache-2.0 许可。宽松许可:允许商业使用、修改和再分发,并附带明确的专利授权;分发时需保留许可与 NOTICE 文件,修改过的文件要注明改动。以上为概括,不构成法律意见,请以许可原文为准。

@gobing-ai/spur 的下载量有多少?

根据 npm 官方下载统计,@gobing-ai/spur 在 2026/10/17 – 2026/11/15 这 30 天内被下载 5,660 次,日均约 189 次。下载量会把 CI 构建、镜像同步和作为其他包依赖的安装一并计入,适合横向比较热度,不能直接等同于使用人数。

@gobing-ai/spur 还在维护吗?

最新版本 0.4.35 发布于 2026/11/15(1 天前);至今共发布 142 个版本,其中过去 12 个月发布了 142 个;首次发布于 2026/06/10。发布频率只是参考信号:功能稳定的工具可能很少需要更新,建议结合源码仓库的 issue 和提交记录判断。