brandrail 0.0.0-stage → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,3 +1,30 @@
1
- # Temporary Holding Version
1
+ # brandrail
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ Keep AI-generated UI on-brand. `brandrail` checks code and live pages against your design system
4
+ (Brand Kit), and writes your rules into the files AI coding tools read.
5
+
6
+ ```bash
7
+ npx brandrail init # brandrail.config.json, src/brandrail.tokens.css + AGENTS.md, CLAUDE.md, Cursor/Copilot/Windsurf/Gemini rules
8
+ npx brandrail check # violations + brand score for this repo
9
+ npx brandrail scan <url> # check a running page in a real browser
10
+ ```
11
+
12
+ ## With a Brandrail account
13
+
14
+ ```bash
15
+ export BRANDRAIL_KEY=br_live_… # Dashboard → Connect → API keys
16
+ npx brandrail init --from-api --mcp # pull your published Brand Kit, add the MCP server to your AI tools
17
+ npx brandrail check --changed --upload # only changed lines, results in the dashboard
18
+ ```
19
+
20
+ ## Commands
21
+
22
+ | Command | |
23
+ | --- | --- |
24
+ | `check [paths]` | `--format pretty\|json\|markdown\|github`, `--fail-below 80`, `--changed [base]`, `--upload` |
25
+ | `scan <url>` | `--pages 3`, `--storage-state auth.json` (pages behind a login), `--wait 2000`, `--upload`. Needs `npm i -D playwright && npx playwright install chromium` |
26
+ | `init` | `--from-api`, `--mcp`, `--tokens-css <file>`, `--no-rules`, `--force`. Writes the Brand Kit as CSS variables; import that file once at your app entry |
27
+ | `import <tokens.json>` | DTCG, Tokens Studio or Figma variables JSON into the config. `--replace`, `--primitives` |
28
+ | `rules` | List the rules |
29
+
30
+ Nothing is uploaded unless you pass `--upload`, and code snippets are never uploaded.