From 5c6099177bb5bb9c0c8b1928973cc8854249ca52 Mon Sep 17 00:00:00 2001 From: Snow Lee Date: Sun, 19 Jul 2026 14:30:06 -0700 Subject: [PATCH] feat: bdrive skill install + one-paste Codex/Hermes setup guide MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The hub's install guide told Codex and Hermes users to run four CLI commands by hand, and the one people skipped — `bdrive hooks install` — is exactly the one that makes files sync at turn boundaries. Hand the setup to the agent instead, the way the Claude tab hands it to the plugin. - `bdrive skill install` (internal/agentskills, plugin/embed.go): the binary now carries the beardrive skill and writes it to any agent that reads SKILL.md — ~/.{claude,codex,gemini,hermes}/skills/beardrive/. User-level on purpose: the skill is about the CLI, not one folder, and a synced project folder should never carry it. Idempotent; refreshes a stale copy after a CLI upgrade. Bare `bdrive skill` prints the table, mirroring `bdrive hooks`. - Guide's Codex/Hermes tabs are now a single paste, no terminal: the prompt has the agent install the CLI, keep the skill, sign in, init, and register hooks. The commands ride inside the prompt because these agents ship no BearDrive knowledge (Claude's tab is terse only because the plugin carries it). `login --device` there — a browser-callback sign-in is invisible to an agent mid-turn, while the device flow gives it a code and URL to relay. Plain commands live on in an "or run it yourself" fallback. - Docs realigned: README, SKILL.md, /beardrive:install, self-hosting. Co-Authored-By: Claude Opus 4.8 (1M context) --- CHANGELOG.md | 13 ++ README.md | 33 +++++ cmd/bdrive/main.go | 1 + cmd/bdrive/skill.go | 87 +++++++++++++ docs/self-hosting.md | 11 +- internal/agentskills/agentskills.go | 123 ++++++++++++++++++ internal/agentskills/agentskills_test.go | 100 ++++++++++++++ internal/webapp/frontend/e2e/home.spec.ts | 22 +++- .../frontend/src/components/ConnectGuide.tsx | 116 ++++++++++++----- internal/webapp/frontend/src/style.css | 6 + .../webapp/static/assets/index-9WanC3kA.css | 1 - .../webapp/static/assets/index-BZPW21Cg.css | 1 + .../{index-QXAy2YSg.js => index-BaEUl3mb.js} | 48 +++---- internal/webapp/static/index.html | 4 +- plugin/commands/install.md | 18 +++ plugin/embed.go | 14 ++ plugin/skills/beardrive/SKILL.md | 35 +++++ 17 files changed, 562 insertions(+), 71 deletions(-) create mode 100644 cmd/bdrive/skill.go create mode 100644 internal/agentskills/agentskills.go create mode 100644 internal/agentskills/agentskills_test.go delete mode 100644 internal/webapp/static/assets/index-9WanC3kA.css create mode 100644 internal/webapp/static/assets/index-BZPW21Cg.css rename internal/webapp/static/assets/{index-QXAy2YSg.js => index-BaEUl3mb.js} (53%) create mode 100644 plugin/embed.go diff --git a/CHANGELOG.md b/CHANGELOG.md index c1149e3..41887a7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,19 @@ Notable changes per release. Format loosely follows [Keep a Changelog](https://keepachangelog.com/); BearDrive is pre-1.0, so minor versions may ship breaking changes (see [SemVer §4](https://semver.org/#spec-item-4)). +## Unreleased + +- **`bdrive skill install`** — the binary now carries the `beardrive` + skill and installs it into any agent that reads `SKILL.md` + (`~/.claude|.codex|.gemini|.hermes/skills/beardrive/`), idempotently; + bare `bdrive skill` prints the detection table. +- **Hub install guide, Codex and Hermes tabs: one paste, no terminal** — + the same shape as the Claude tab. The pasted prompt has the agent install + the CLI, keep the skill, sign in (`login --device`, so it can relay the + code instead of hoping a browser opened), `bdrive init`, and + `bdrive hooks install` — the step hand-copied setups routinely skipped. + The plain commands moved into an "or run it yourself" fallback. + ## v0.8.0 — 2026-07-16 - **Gated links on every mentioned file path**: Claude Code's turn-start diff --git a/README.md b/README.md index 7a7fe42..9d1071b 100644 --- a/README.md +++ b/README.md @@ -143,6 +143,7 @@ hub's own storage, never something a syncing client points at directly: | `bdrive share ` | Public URL for a synced file (`--list`, `--revoke`, `--expires`) | | `bdrive sync [folder]` | Run one sync cycle now. `--note ` stamps session context (e.g. an agent session id) onto changes — shown in `bdrive log` and hub history; keeps applying to daemon-committed changes until `--note-ttl` (default 30m) expires. `--hook