bmad-sync-standards
Sync engineering standards from a central catalog into the current project's docs/standards/ folder, based on the project's engineering-standards.yml manifest. Also generates .cursor/rules/*.mdc and updates CLAUDE.md @imports for editor parity. Use when user says "sync standards", "pull standards", "update standards", or after editing engineering-standards.yml.
- License 许可
- MIT
- 最近更新
- 2026-06-05
- Stars
- ★ 0
- Forks
- 1
01 前言 Front Matter
- name
- bmad-sync-standards
- description
- Sync engineering standards from a central catalog into the current project's docs/standards/ folder, based on the project's engineering-standards.yml manifest. Also generates .cursor/rules/*.mdc and updates CLAUDE.md @imports for editor parity. Use when user says "sync standards", "pull standards", "update standards", or after editing engineering-standards.yml.
03 SKILL.md 正文
Sync Engineering Standards
Pull a project-specific subset of the central engineering-standards catalog into the project. BMAD skills (create-architecture, create-story, dev-story, code-review) read these from docs/standards/ and treat constraints as binding.
When to Use
- New project: after dropping
engineering-standards.ymlat root. - Updated manifest: added/removed a domain.
- Catalog refresh: standards repo got new docs.
- Onboarding teammate: ensures their checkout has the latest synced standards.
What This Does
- Reads
engineering-standards.ymlat project root. - Fetches catalog (local path or git URL, per manifest).
- Copies listed domain folders into
docs/standards/<domain>/. - Writes
docs/standards/INDEX.mdlisting what's synced + summaries. - Generates
.cursor/rules/<domain>.mdcfor each domain (Cursor parity). - Adds
@docs/standards/INDEX.mdtoCLAUDE.mdif not already present. - Reports what changed.
Manifest Format
engineering-standards.yml at project root:
catalog: /Users/Sachin/Workspace/engineering-standards # local path OR git URL
version: main # branch/tag/commit (git only)
standards:
- frappe
- python-backend
- redis
- elasticrun-design
If catalog starts with http://, https://, or git@, treat as git URL → clone shallow into .standards-cache/ (gitignored). Otherwise treat as local filesystem path → copy directly.
Process
1. Validate manifest
- Ensure
engineering-standards.ymlexists at project root. If not, halt with: "Noengineering-standards.ymlfound. Create one at project root listing the catalog and the domains this project uses." - Parse YAML. Validate keys:
catalog(required),standards(required, list),version(optional).
2. Fetch catalog
Local path:
cp -r <catalog>/<domain>/ docs/standards/<domain>/for each listed domain.- Skip domains not present in catalog. Warn user.
Git URL:
- If
.standards-cache/doesn't exist:git clone --depth 1 -b <version> <catalog> .standards-cache/. - Else:
cd .standards-cache && git fetch && git checkout <version> && git pull. - Add
.standards-cache/to.gitignoreif missing. - Then copy domain folders as in local case.
3. Refresh docs/standards/
- Wipe existing
docs/standards/first (clean slate, no stale files). - Copy each domain folder.
- Write
docs/standards/INDEX.md(template below).
4. Generate Cursor rules
For each synced domain, write .cursor/rules/standards-<domain>.mdc:
---
description: <Domain> engineering standards (synced from central catalog)
globs:
alwaysApply: true
---
<concatenated content of all .md files in docs/standards/<domain>/>
alwaysApply: true ensures Cursor loads them on every chat.
5. Update CLAUDE.md
- If
CLAUDE.mddoesn't exist at project root: skip (don't create one). - If exists: check for
@docs/standards/INDEX.md. If missing, append a section:
## Engineering Standards
@docs/standards/INDEX.md
These rules are binding for all generated code.
6. Report
Print a table to user:
| Domain | Files synced | Source |
|---|---|---|
| frappe | 10 | catalog/frappe/ |
| python-backend | 4 | catalog/python-backend/ |
| ... | ... | ... |
Plus: cursor rules generated, CLAUDE.md updated/skipped.
INDEX.md Template
# Engineering Standards (synced)
Last synced: <ISO date>
Catalog: <catalog path or URL>
Version: <version>
These standards are binding. BMAD skills (create-architecture, create-story, dev-story, code-review) treat constraints in these files as hard requirements unless explicitly overridden in project-context.md.
## Domains
### frappe
- [Mental Model](frappe/mental-model.md)
- [Doctype Patterns](frappe/doctype-patterns.md)
- ... (auto-list all .md files)
### python-backend
- ...
(repeat per domain)
## Override Rules
If a project rule conflicts with a standard, document the override in `project-context.md` under "Standards Overrides" with the reason. Otherwise, standards win.
Rules
- Never edit files inside
docs/standards/by hand. They get wiped on next sync. Project-specific overrides go inproject-context.md. .standards-cache/always gitignored.- If a listed domain doesn't exist in catalog, warn but don't fail. Skip it.
- Idempotent. Running twice = same result.
Don't
- Sync without a manifest. No silent defaults.
- Skip cursor rule generation. 70% of team uses Cursor.
- Modify catalog from a project. Catalog is upstream-only.
- Commit
.standards-cache/to project repo.
04 同仓库更多 Skills
dontbmad-grill
Interview the user relentlessly on a plan, decision, or artifact until every branch of the decision tree is resolved. One question at a time, with a recommended answer for each. Reads existing artifacts and codebase before asking. Use when the user says "grill me", "stress-test this plan", "interrogate this", or when invoked from a BMAD planning skill (architecture, PRD, story, UX) before finalizing the artifact.
dontbmad-graphify
暂无简介
dontbmad-graphify-query
暂无简介
dontbmad-graphify-path
暂无简介
dontbmad-graphify-explain
暂无简介
dontbmad-compress-artifacts
Compress BMAD planning artifacts (PRDs, architecture docs, stories, project-context) into terse format to reduce input tokens when agents read them. Originals backed up as .original.md. Use when user says "compress artifacts", "compress planning docs", or "shrink the docs".