rn-agent-kit 0.2.0 → 0.2.1
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 +169 -54
- package/package.json +5 -3
package/README.md
CHANGED
|
@@ -1,28 +1,121 @@
|
|
|
1
1
|
# rn-agent-kit
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
**One CLI** that installs React Native / Expo **agent skills** into Claude, Cursor, Copilot, Windsurf, and `AGENTS.md`, plus optional design→tokens→Jira→Maestro→CI workflow.
|
|
4
|
+
|
|
5
|
+
[npm](https://www.npmjs.com/package/rn-agent-kit) · Requires **Node.js >= 18**
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Install
|
|
4
10
|
|
|
5
11
|
```bash
|
|
12
|
+
# Use without adding a dependency (recommended)
|
|
13
|
+
npx rn-agent-kit@latest init
|
|
14
|
+
|
|
15
|
+
# Or add to your app
|
|
16
|
+
npm install -D rn-agent-kit
|
|
6
17
|
npx rn-agent-kit init
|
|
7
|
-
npx rn-agent-kit doctor
|
|
8
|
-
npx rn-agent-kit update
|
|
9
|
-
npx rn-agent-kit tokens build
|
|
10
|
-
npx rn-agent-kit jira-validate
|
|
11
18
|
```
|
|
12
19
|
|
|
13
|
-
|
|
20
|
+
After `init`, skills are copied into your project (e.g. `.cursor/rules/`, `.claude/skills/`). Run `npx rn-agent-kit doctor` to verify your machine.
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## Prerequisites (install these first)
|
|
25
|
+
|
|
26
|
+
### Required for the CLI
|
|
27
|
+
|
|
28
|
+
| Tool | Why | Install |
|
|
29
|
+
| ------------------------------------ | ---------------------------- | --------------------------------------------------------- |
|
|
30
|
+
| **Node.js 18+** (20 LTS recommended) | Runs `rn-agent-kit` | [nodejs.org](https://nodejs.org/) or `brew install node` |
|
|
31
|
+
| **npm** or **yarn** / **pnpm** | Package manager | Comes with Node / `corepack enable` |
|
|
32
|
+
| **Git** | Branches in `ticket-to-code` | [git-scm.com](https://git-scm.com/) or `brew install git` |
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
node -v # >= 18
|
|
36
|
+
npm -v
|
|
37
|
+
git --version
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
### Required for a React Native / Expo app
|
|
41
|
+
|
|
42
|
+
You need an RN or Expo app (or let `init --type new` create one).
|
|
43
|
+
|
|
44
|
+
| Tool | Why | Install |
|
|
45
|
+
| --------------------------------- | --------------------- | --------------------------------- |
|
|
46
|
+
| **Expo CLI** (if Expo) | Dev client / prebuild | `npm i -g expo` or use `npx expo` |
|
|
47
|
+
| **Watchman** (macOS, recommended) | Metro file watching | `brew install watchman` |
|
|
48
|
+
|
|
49
|
+
### Optional — native builds & E2E
|
|
50
|
+
|
|
51
|
+
| Tool | Why | Install |
|
|
52
|
+
| ------------------------ | ------------------------------- | ----------------------------------------------------------------------------------------- |
|
|
53
|
+
| **JDK 17** | Android Gradle | `brew install --cask temurin@17` |
|
|
54
|
+
| **Android Studio + SDK** | Android builds / emulator | [developer.android.com/studio](https://developer.android.com/studio) — set `ANDROID_HOME` |
|
|
55
|
+
| **Xcode** (macOS) | iOS builds / simulator | Mac App Store + `xcode-select --install` |
|
|
56
|
+
| **CocoaPods** | iOS deps | `sudo gem install cocoapods` or `brew install cocoapods` |
|
|
57
|
+
| **Maestro** | E2E flows (`maestro-e2e` skill) | `curl -fsSL "https://get.maestro.mobile.dev" \| bash` then add `~/.maestro/bin` to `PATH` |
|
|
58
|
+
| **EAS CLI** | Cloud builds (optional) | `npm i -g eas-cli` |
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
# Maestro
|
|
62
|
+
curl -fsSL "https://get.maestro.mobile.dev" | bash
|
|
63
|
+
echo 'export PATH="$PATH:$HOME/.maestro/bin"' >> ~/.zshrc && source ~/.zshrc
|
|
64
|
+
maestro --version
|
|
65
|
+
```
|
|
66
|
+
|
|
67
|
+
### Optional — design / Jira MCP
|
|
68
|
+
|
|
69
|
+
| Need | Install / setup |
|
|
70
|
+
| -------------------- | ------------------------------------------------------------------------- |
|
|
71
|
+
| Figma MCP + token | `init --sdlc` writes MCP stubs; set `FIGMA_TOKEN` or `FIGMA_ACCESS_TOKEN` |
|
|
72
|
+
| Atlassian / Jira MCP | Same; set `JIRA_SITE_URL`, `JIRA_EMAIL`, `JIRA_API_TOKEN` |
|
|
73
|
+
|
|
74
|
+
---
|
|
75
|
+
|
|
76
|
+
## Recommended packages in your RN app
|
|
77
|
+
|
|
78
|
+
`rn-agent-kit` does **not** auto-install app libraries. After `init`, install what your stack uses (skills assume these):
|
|
79
|
+
|
|
80
|
+
```bash
|
|
81
|
+
# State / data (rn-architecture skill)
|
|
82
|
+
npx expo install @tanstack/react-query zustand
|
|
83
|
+
# or: npm i @tanstack/react-query zustand
|
|
84
|
+
|
|
85
|
+
# Validation (rn-typescript-react)
|
|
86
|
+
npm i zod
|
|
87
|
+
|
|
88
|
+
# Lists (performance)
|
|
89
|
+
npm i @shopify/flash-list
|
|
90
|
+
|
|
91
|
+
# Theme / navigation (Expo)
|
|
92
|
+
npx expo install expo-router expo-constants expo-secure-store
|
|
93
|
+
|
|
94
|
+
# Testing
|
|
95
|
+
npm i -D jest @testing-library/react-native @types/jest
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
Lint guard for hardcoded design values (from this package’s templates):
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
# After init --sdlc / copying templates/eslint
|
|
102
|
+
npm i -D eslint prettier typescript-eslint eslint-config-prettier
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
---
|
|
14
106
|
|
|
15
107
|
## Quick start
|
|
16
108
|
|
|
17
109
|
```bash
|
|
18
|
-
#
|
|
19
|
-
|
|
110
|
+
# Existing RN/Expo app
|
|
111
|
+
cd your-app
|
|
112
|
+
npx rn-agent-kit@latest init --yes --type existing --tools claude,cursor,agents-md
|
|
20
113
|
|
|
21
|
-
#
|
|
22
|
-
npx rn-agent-kit init --yes --type new --stack expo --name MyApp --tools claude,cursor
|
|
114
|
+
# New Expo app + architecture scaffold + skills
|
|
115
|
+
npx rn-agent-kit@latest init --yes --type new --stack expo --name MyApp --tools claude,cursor
|
|
23
116
|
|
|
24
|
-
#
|
|
25
|
-
npx rn-agent-kit init --yes --type existing --sdlc \
|
|
117
|
+
# Full SDLC stubs (MCP, Maestro folder, GitHub workflows)
|
|
118
|
+
npx rn-agent-kit@latest init --yes --type existing --sdlc \
|
|
26
119
|
--jira-url https://acme.atlassian.net --jira-key APP \
|
|
27
120
|
--figma-url https://www.figma.com/design/AbC/App \
|
|
28
121
|
--github-repo acme/my-app --tools claude,cursor
|
|
@@ -30,6 +123,17 @@ npx rn-agent-kit init --yes --type existing --sdlc \
|
|
|
30
123
|
npx rn-agent-kit doctor
|
|
31
124
|
```
|
|
32
125
|
|
|
126
|
+
### Useful commands
|
|
127
|
+
|
|
128
|
+
```bash
|
|
129
|
+
npx rn-agent-kit update # refresh skills only
|
|
130
|
+
npx rn-agent-kit tokens build # design/source-snapshot.json → theme
|
|
131
|
+
npx rn-agent-kit tokens check # CI gate
|
|
132
|
+
npx rn-agent-kit jira-validate # ticket markdown checks
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
---
|
|
136
|
+
|
|
33
137
|
## Full workflow
|
|
34
138
|
|
|
35
139
|
```text
|
|
@@ -56,20 +160,22 @@ npx rn-agent-kit doctor
|
|
|
56
160
|
└──────────────────┘
|
|
57
161
|
```
|
|
58
162
|
|
|
59
|
-
Skills
|
|
163
|
+
Skills ship inside this package under `skills/*/SKILL.md` and are installed by adapters (`init` / `update`).
|
|
164
|
+
|
|
165
|
+
---
|
|
60
166
|
|
|
61
167
|
## Required secrets
|
|
62
168
|
|
|
63
169
|
### Local / MCP (never commit)
|
|
64
170
|
|
|
65
|
-
| Variable | Purpose
|
|
66
|
-
| ------------------------------------- |
|
|
67
|
-
| `FIGMA_TOKEN` or `FIGMA_ACCESS_TOKEN` | Figma REST `tokens fetch` + Figma MCP
|
|
68
|
-
| `JIRA_SITE_URL` |
|
|
69
|
-
| `JIRA_EMAIL` | Atlassian account email
|
|
70
|
-
| `JIRA_API_TOKEN` | [
|
|
171
|
+
| Variable | Purpose |
|
|
172
|
+
| ------------------------------------- | --------------------------------------------------------------------------- |
|
|
173
|
+
| `FIGMA_TOKEN` or `FIGMA_ACCESS_TOKEN` | Figma REST `tokens fetch` + Figma MCP |
|
|
174
|
+
| `JIRA_SITE_URL` | e.g. `https://acme.atlassian.net` |
|
|
175
|
+
| `JIRA_EMAIL` | Atlassian account email |
|
|
176
|
+
| `JIRA_API_TOKEN` | [Create token](https://id.atlassian.com/manage-profile/security/api-tokens) |
|
|
71
177
|
|
|
72
|
-
`.agent/config.json`
|
|
178
|
+
`.agent/config.json` holds **non-secrets only** (`jira.siteUrl`, `jira.projectKey`, `figma.fileUrl`, `confirm`).
|
|
73
179
|
|
|
74
180
|
### GitHub Actions (consumer apps)
|
|
75
181
|
|
|
@@ -80,9 +186,11 @@ Skills live under `skills/*/SKILL.md` and are installed by adapters (`init` / `u
|
|
|
80
186
|
| `JIRA_API_TOKEN` | Optional | same |
|
|
81
187
|
| `EXPO_TOKEN` | Only if you keep `eas-build.yml` | EAS Build / Submit |
|
|
82
188
|
|
|
83
|
-
Repo **variable**: `APP_ID` (bundle id / applicationId for Maestro).
|
|
189
|
+
Repo **variable**: `APP_ID` (iOS bundle id / Android applicationId for Maestro).
|
|
190
|
+
|
|
191
|
+
Workflow templates: `templates/workflows/{ci,e2e-android,e2e-ios,eas-build}.yml` — **`eas-build.yml` is optional**.
|
|
84
192
|
|
|
85
|
-
|
|
193
|
+
---
|
|
86
194
|
|
|
87
195
|
## Per-tool setup
|
|
88
196
|
|
|
@@ -90,88 +198,95 @@ Templates: `templates/workflows/{ci,e2e-android,e2e-ios,eas-build}.yml` (`eas-bu
|
|
|
90
198
|
|
|
91
199
|
```bash
|
|
92
200
|
npx rn-agent-kit init -t claude
|
|
93
|
-
#
|
|
201
|
+
# → .claude/skills/<name>/SKILL.md
|
|
94
202
|
```
|
|
95
203
|
|
|
96
|
-
Open the project in Claude Code; skills under `.claude/skills` are picked up automatically.
|
|
97
|
-
|
|
98
204
|
### Cursor
|
|
99
205
|
|
|
100
206
|
```bash
|
|
101
207
|
npx rn-agent-kit init -t cursor
|
|
102
|
-
#
|
|
208
|
+
# → .cursor/rules/<name>.mdc
|
|
103
209
|
```
|
|
104
210
|
|
|
105
|
-
|
|
211
|
+
MCP: merge `.cursor/mcp.json` from `init --sdlc`.
|
|
106
212
|
|
|
107
|
-
### Codex / Gemini / others
|
|
213
|
+
### Codex / Gemini / others
|
|
108
214
|
|
|
109
215
|
```bash
|
|
110
216
|
npx rn-agent-kit init -t agents-md
|
|
111
217
|
```
|
|
112
218
|
|
|
113
|
-
|
|
219
|
+
Only the block between `<!-- rn-agent-kit:start -->` and `<!-- rn-agent-kit:end -->` is managed.
|
|
114
220
|
|
|
115
221
|
### GitHub Copilot
|
|
116
222
|
|
|
117
223
|
```bash
|
|
118
224
|
npx rn-agent-kit init -t copilot
|
|
119
|
-
# .github/copilot-instructions.md
|
|
225
|
+
# → .github/copilot-instructions.md
|
|
120
226
|
```
|
|
121
227
|
|
|
122
228
|
### Windsurf
|
|
123
229
|
|
|
124
230
|
```bash
|
|
125
231
|
npx rn-agent-kit init -t windsurf
|
|
126
|
-
# .windsurf/rules/<name>.md
|
|
232
|
+
# → .windsurf/rules/<name>.md
|
|
127
233
|
```
|
|
128
234
|
|
|
129
235
|
### Refresh skills later
|
|
130
236
|
|
|
131
237
|
```bash
|
|
132
|
-
npx rn-agent-kit update
|
|
238
|
+
npx rn-agent-kit update
|
|
133
239
|
npx rn-agent-kit update -a cursor,claude
|
|
134
240
|
```
|
|
135
241
|
|
|
242
|
+
---
|
|
243
|
+
|
|
136
244
|
## CLI reference
|
|
137
245
|
|
|
138
|
-
| Command | Role
|
|
139
|
-
| --------------- |
|
|
140
|
-
| `init` | New/existing project, adapters, optional SDLC
|
|
141
|
-
| `doctor` | Node, git, Java, ANDROID_HOME, Xcode
|
|
142
|
-
| `update` | Re-install skills;
|
|
143
|
-
| `tokens` | `build` \| `generate` \| `check` \| `fetch`
|
|
144
|
-
| `jira-validate` | Fail if tickets lack Figma link / AC / testIDs
|
|
246
|
+
| Command | Role |
|
|
247
|
+
| --------------- | --------------------------------------------------------------------------------------- |
|
|
248
|
+
| `init` | New/existing project, adapters, optional SDLC |
|
|
249
|
+
| `doctor` | Node, git, Java, ANDROID_HOME, Xcode, Maestro, MCP, env, `.agent/config.json`, adapters |
|
|
250
|
+
| `update` | Re-install skills; keeps user text outside markers |
|
|
251
|
+
| `tokens` | `build` \| `generate` \| `check` \| `fetch` |
|
|
252
|
+
| `jira-validate` | Fail if tickets lack Figma link / AC / testIDs |
|
|
253
|
+
|
|
254
|
+
---
|
|
145
255
|
|
|
146
256
|
## FAQ
|
|
147
257
|
|
|
148
|
-
**
|
|
149
|
-
|
|
258
|
+
**README npm pe nahi dikhti thi?**
|
|
259
|
+
Pehle publish incomplete / purani version ho sakti thi. Latest: `https://www.npmjs.com/package/rn-agent-kit` — hard refresh. Local file hamesha repo root `README.md` mein hai.
|
|
260
|
+
|
|
261
|
+
**`init --yes` existing app ke folders change karega?**
|
|
262
|
+
Nahi. Scaffold sirf confirm ke baad (interactive). `--yes` restructure skip karta hai.
|
|
150
263
|
|
|
151
|
-
|
|
152
|
-
|
|
264
|
+
**`tokens.ts` hand-edit?**
|
|
265
|
+
Nahi — `rn-agent-kit tokens build` / `generate`. Design source fix karo.
|
|
153
266
|
|
|
154
|
-
**
|
|
155
|
-
|
|
267
|
+
**iOS E2E har PR pe?**
|
|
268
|
+
Nahi by default (macOS cost). Template: main / nightly / manual.
|
|
156
269
|
|
|
157
|
-
**
|
|
158
|
-
|
|
270
|
+
**Doctor Maestro / Android warn — fatal?**
|
|
271
|
+
Warn = optional tooling. Fail = e.g. Node < 18 ya invalid `.agent/config.json`.
|
|
159
272
|
|
|
160
|
-
|
|
161
|
-
Those are **warnings** for day-to-day JS work. **Failures** are things like Node < 18 or invalid `.agent/config.json`.
|
|
273
|
+
---
|
|
162
274
|
|
|
163
|
-
## Develop (
|
|
275
|
+
## Develop (contributors)
|
|
164
276
|
|
|
165
277
|
```bash
|
|
278
|
+
git clone <this-repo>
|
|
279
|
+
cd rn-agent-kit
|
|
166
280
|
npm install
|
|
167
281
|
npm test
|
|
168
282
|
npm run typecheck
|
|
169
283
|
npm run build
|
|
170
284
|
```
|
|
171
285
|
|
|
172
|
-
Versioning
|
|
286
|
+
Versioning: [Changesets](https://github.com/changesets/changesets). CI publish: `.github/workflows/publish.yml` (`NPM_TOKEN` secret).
|
|
287
|
+
|
|
288
|
+
---
|
|
173
289
|
|
|
174
|
-
##
|
|
290
|
+
## License
|
|
175
291
|
|
|
176
|
-
|
|
177
|
-
- **Needs manual verification before relying in production:** live Figma REST/MCP payloads, live Atlassian issue create, real Stitch export shape, Maestro on real devices/emulators, EAS credentials, Xcode scheme names in consumer apps.
|
|
292
|
+
MIT
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rn-agent-kit",
|
|
3
|
-
"version": "0.2.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "0.2.1",
|
|
4
|
+
"description": "Install React Native / Expo agent skills into Claude, Cursor, Copilot, Windsurf + AGENTS.md. Includes tokens, Jira, Maestro, CI templates.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
7
7
|
"rn-agent-kit": "dist/cli.js"
|
|
@@ -9,7 +9,9 @@
|
|
|
9
9
|
"files": [
|
|
10
10
|
"dist",
|
|
11
11
|
"skills",
|
|
12
|
-
"templates"
|
|
12
|
+
"templates",
|
|
13
|
+
"README.md",
|
|
14
|
+
"LICENSE"
|
|
13
15
|
],
|
|
14
16
|
"engines": {
|
|
15
17
|
"node": ">=18"
|