spawn-cli 0.1.10__tar.gz → 0.1.12__tar.gz

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.
Files changed (49) hide show
  1. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/PKG-INFO +34 -10
  2. spawn_cli-0.1.10/src/spawn_cli.egg-info/PKG-INFO → spawn_cli-0.1.12/README.md +221 -214
  3. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/pyproject.toml +1 -1
  4. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/core/scripts.py +17 -0
  5. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/io/lock.py +3 -1
  6. spawn_cli-0.1.10/README.md → spawn_cli-0.1.12/src/spawn_cli.egg-info/PKG-INFO +238 -197
  7. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/tests/test_cli.py +4 -2
  8. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/LICENSE +0 -0
  9. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/setup.cfg +0 -0
  10. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/__init__.py +0 -0
  11. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/cli.py +0 -0
  12. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/core/__init__.py +0 -0
  13. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/core/download.py +0 -0
  14. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/core/errors.py +0 -0
  15. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/core/high_level.py +0 -0
  16. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/core/low_level.py +0 -0
  17. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/errors.py +0 -0
  18. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/ide/__init__.py +0 -0
  19. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/ide/_helpers.py +0 -0
  20. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/ide/_stub.py +0 -0
  21. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/ide/_vacancy.py +0 -0
  22. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/ide/claude_code.py +0 -0
  23. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/ide/codex.py +0 -0
  24. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/ide/cursor.py +0 -0
  25. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/ide/gemini_cli.py +0 -0
  26. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/ide/github_copilot.py +0 -0
  27. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/ide/registry.py +0 -0
  28. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/ide/windsurf.py +0 -0
  29. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/io/__init__.py +0 -0
  30. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/io/json_io.py +0 -0
  31. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/io/paths.py +0 -0
  32. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/io/text_io.py +0 -0
  33. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/io/toml_io.py +0 -0
  34. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/io/yaml_io.py +0 -0
  35. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/models/__init__.py +0 -0
  36. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/models/config.py +0 -0
  37. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/models/mcp.py +0 -0
  38. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/models/metadata.py +0 -0
  39. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/models/navigation.py +0 -0
  40. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/models/skill.py +0 -0
  41. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/resources/__init__.py +0 -0
  42. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/resources/default_core_config.yaml +0 -0
  43. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli/warnings_display.py +0 -0
  44. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli.egg-info/SOURCES.txt +0 -0
  45. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli.egg-info/dependency_links.txt +0 -0
  46. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli.egg-info/entry_points.txt +0 -0
  47. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli.egg-info/requires.txt +0 -0
  48. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/src/spawn_cli.egg-info/top_level.txt +0 -0
  49. {spawn_cli-0.1.10 → spawn_cli-0.1.12}/tests/test_warnings_display.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: spawn-cli
3
- Version: 0.1.10
3
+ Version: 0.1.12
4
4
  Summary: A minimal installable Python CLI package.
5
5
  License: MIT
6
6
  Classifier: License :: OSI Approved :: MIT License
@@ -181,7 +181,7 @@ spawn extension init ./my-extension --name my-extension
181
181
 
182
182
  **Agent-guided scaffold** with **[spawn-ext-creator](https://github.com/noant/spawn-ext-creator)** (install the extension above, then `spawn ide add <ide>` so skills render into your IDE): invoke the **`spawn-ext-bootstrap`** skill so the agent lays out a fuller extension repo than the bare CLI skeleton—for example:
183
183
 
184
- > Use the **spawn-ext-bootstrap** skill to bootstrap a new Spawn extension with stable id `my-extension` under `./my-extension`.
184
+ > Use the **spawn-ext-bootstrap** skill to bootstrap a new Spawn extension.
185
185
 
186
186
  Other creator skills (declaring `config.yaml`, skill sources, MCP, verification, etc.) ship under the same extension; see the rendered skill list after install.
187
187
 
@@ -189,25 +189,49 @@ Read **[spec/design/extension-author-guide.md](spec/design/extension-author-guid
189
189
 
190
190
  **Minimal mental model:**
191
191
 
192
- - `**extsrc/config.yaml`** — `schema`, `version`, stable `**name`** (install path `spawn/.extend/<name>/`), plus `files`, `skills`, ignores, optional `hints`, etc.
193
- - `**extsrc/files/**` — template tree mirrored into the target repo according to `files:` entries.
194
- - `**spawn extension check . --strict**` — validate before publishing or tagging a release.
192
+ - `extsrc/config.yaml` — `schema`, `version`, stable `name` (install path `spawn/.extend/<name>/`), plus `files`, `skills`, ignores, optional `hints`, etc.
193
+ - `extsrc/files/` — template tree mirrored into the target repo according to `files:` entries.
194
+ - `spawn extension check . --strict` — validate before publishing or tagging a release.
195
195
 
196
196
  ## How to add rules without creating an extension
197
197
 
198
- Project-local conventions can live under **`spawn/rules/`** without packaging them as an extension. After **`spawn init`**, add any files there (for example `spawn/rules/team.md`); Spawn discovers **every file** under that directory tree.
198
+ You can steer agents in two complementary ways that do **not** require an extension: **rule files** under **`spawn/rules/`** (content the agent must or may read), and **short hints** in **`spawn/navigation.yaml`** (reminders merged into rendered skills and IDE entry-point blocks such as **`AGENTS.md`**).
199
199
 
200
- Wire those paths into **`spawn/navigation.yaml`** so mandatory reads stay aligned with what is on disk:
200
+ **After edits** to **`spawn/rules/**` or to rule rows / **`hint`** in **`spawn/navigation.yaml`**, run **`spawn refresh`** so navigation, skills, and entry points stay in sync. **`spawn rules refresh`** only syncs **`spawn/rules/**` into **`navigation.yaml`**—no skill or entry-point updates.
201
+
202
+ ### 1. Rule files
203
+
204
+ Project-local conventions live as files under **`spawn/rules/`**. After **`spawn init`**, add any files there (for example **`spawn/rules/team.md`**); Spawn discovers **every file** under that directory tree.
205
+
206
+ Wire those paths into **`spawn/navigation.yaml`** so reads stay aligned with what is on disk:
201
207
 
202
208
  ```bash
203
- spawn rules refresh
209
+ spawn refresh
204
210
  ```
205
211
 
206
212
  That rescans **`spawn/rules/`**, attaches missing rule files under a **`rules`** group inside **`read-required`** (default description **`Local rule file.`** until you edit it), and drops stale entries whose files were deleted (you may see a warning).
207
213
 
208
- Rule files can be **mandatory** (**`read-required`**) or **contextual** (**`read-contextual`**). **`spawn rules refresh`** only auto-adds **new** paths into **`read-required` → `rules`**. To keep a rule **contextual**, declare it under **`read-contextual` → `rules`** in **`spawn/navigation.yaml`** with the same shape (`path`, `description`)—once a path appears in either rules list, refresh will not duplicate it into the other tier. You can move entries between **`read-required`** and **`read-contextual`** by editing **`spawn/navigation.yaml`**, then run **`spawn rules refresh`** so both lists stay consistent with files on disk.
214
+ **Tiers:** list a rule under **`read-required` → `rules`** (always read) or **`read-contextual` → `rules`** (read when relevant). Use the same row shape (`path`, `description`). A path must not appear in both lists—after you move a row, rerun **`spawn refresh`** (or **`spawn rules refresh`** if you only need YAML). New files discovered on disk are appended to **`read-required` → `rules`** until you relocate them.
215
+
216
+ **Extension reads:** **`ext:`** blocks are unrelated; repo-local rule paths live only under **`spawn/rules/**`** and the **`rules`** groups in **`spawn/navigation.yaml`**.
217
+
218
+ ### 2. Hints in `spawn/navigation.yaml`
219
+
220
+ For **short, always-visible reminders** (tone, language, repo-specific habits), add an optional **`hint`** field on rows under **`read-required` → `rules`**—alongside **`path`** and **`description`**.
221
+
222
+ Spawn merges those strings into the **Hints** section of **rendered skills** and into the **Hints** rollup in managed IDE entry points (for example **`AGENTS.md`**), using the same ordering and deduping rules as extension **`hints.global`**.
223
+
224
+ Example:
225
+
226
+ ```yaml
227
+ read-required:
228
+ - rules:
229
+ - path: spawn/rules/team.md
230
+ description: Team conventions.
231
+ hint: Prefer British spelling in user-facing copy.
232
+ ```
209
233
 
210
- Extension-backed reads (`ext:` entries) are unrelated—you only maintain **`spawn/rules/**`** plus **`spawn rules refresh`** for repo-local rules.
234
+ Then run **`spawn refresh`** so skills and entry points pick up the hint.
211
235
 
212
236
  ## License
213
237
 
@@ -1,214 +1,221 @@
1
- Metadata-Version: 2.4
2
- Name: spawn-cli
3
- Version: 0.1.10
4
- Summary: A minimal installable Python CLI package.
5
- License: MIT
6
- Classifier: License :: OSI Approved :: MIT License
7
- Requires-Python: >=3.10
8
- Description-Content-Type: text/markdown
9
- License-File: LICENSE
10
- Requires-Dist: pydantic>=2.0
11
- Requires-Dist: ruamel.yaml>=0.18
12
- Requires-Dist: filelock>=3.12
13
- Requires-Dist: httpx>=0.27
14
- Requires-Dist: tomli>=2.0; python_version < "3.11"
15
- Requires-Dist: tomli-w>=1.0
16
- Dynamic: license-file
17
-
18
- ## What is Spawn?
19
-
20
- Spawn is a framework for building **AIDD** (AI-driven development) methodologies. It supports both **authoring** methodologies and **applying** them in a project. Within a single repository you can use **several** AIDD methodologies in a coherent way—shared navigation, skills, rules, and tooling stay aligned instead of competing ad hoc setups.
21
-
22
- ## What is spawn-cli?
23
-
24
- **spawn-cli** is the utility that manages methodologies installed in your project. In Spawn terminology those packs are **extensions**: versioned content that usually lives in a **Git** repository. The CLI **instantiates** instruction files, process descriptions, rules, agent skills, and wires their behavior together (navigation, IDE-facing outputs, optional lifecycle hooks). Extensions can also declare **MCP servers**, **agent-ignore** patterns, **git-ignore** entries, and similar integration points—see [`spec/design/extension-author-guide.md`](spec/design/extension-author-guide.md).
25
-
26
- ### How spawn-cli keeps methodologies coherent
27
-
28
- Several methodologies in one repo stay aligned because Spawn maintains **one shared navigation index**: [`spawn/navigation.yaml`](spec/design/data-structure.md) aggregates mandatory and contextual reads from **every installed extension** plus local [`spawn/rules/`](spec/design/user-guide.md) (refreshed with `spawn rules refresh`). Agents are steered through that file instead of chasing disconnected README fragments.
29
-
30
- On each install or refresh, the CLI **regenerates IDE-facing artifacts** so skills and entry points stay consistent across extensions: rendered skill bodies include **paths and descriptions** wired from navigation (required reads, contextual hints, rule files), MCP snippets normalize server definitions per IDE adapter, and ignore lists merge without manual copy-paste. The net effect is that methodology files, generated skill links, and repo rules **compose** rather than contradict each other. Optional `hints` add short reminders to rendered skills and the Spawn-managed entry block.
31
-
32
- **Example:** [**spawn-ext-spectask**](https://github.com/noant/spawn-ext-spectask) (Spec-Tasks methodology: spec layout, skills, design index) and [**spawn-ext-creator**](https://github.com/noant/spawn-ext-creator) (authoring flows, including agent-guided extension bootstrap) can be installed in the **same** repository and still share that single index and merged IDE outputs.
33
-
34
- ## How to install spawn-cli
35
-
36
- **Recommended:** install `spawn` on your `PATH` with **uv**:
37
-
38
- ```bash
39
- uv tool install spawn-cli && spawn --help
40
- ```
41
-
42
- Run once without installing (ephemeral **uvx**):
43
-
44
- ```bash
45
- uvx --from spawn-cli spawn --help
46
- ```
47
-
48
- **Upgrade** the persistent uv tool:
49
-
50
- ```bash
51
- uv tool upgrade spawn-cli && spawn --help
52
- ```
53
-
54
- Force a fresh resolver for a one-shot run:
55
-
56
- ```bash
57
- uvx --refresh --from spawn-cli spawn --help
58
- ```
59
-
60
- Additional installers (**pip**, **pipx**, local checkout) and upgrade notes: **[spec/design/user-guide.md](spec/design/user-guide.md#other-installation-options)**.
61
-
62
- ## How spawn-cli works
63
-
64
- Run commands from the **root of the repository** you are configuring. Almost every command requires `spawn init` first (it creates the `spawn/` tree). Only one Spawn process should touch a repo at a time (file lock).
65
-
66
- ### Initialize a repo
67
-
68
- ```bash
69
- spawn init
70
- ```
71
-
72
- ### IDE adapters
73
-
74
- For each **supported IDE** adapter, show whether it **looks used in the current repository** and what it can render (e.g. skills, MCP, agent-ignore):
75
-
76
- ```bash
77
- spawn ide list-supported-ides
78
- ```
79
-
80
- Register or drop IDE keys for **this** repo (examples: `cursor`, `codex`):
81
-
82
- ```bash
83
- spawn ide add cursor
84
- spawn ide add cursor codex
85
- spawn ide remove codex
86
- spawn ide list
87
- ```
88
-
89
- ### Extensions
90
-
91
- Add from a Git URL, optional branch (also supports ZIP paths and local directories/archives):
92
-
93
- ```bash
94
- spawn extension add https://github.com/noant/spawn-ext-spectask
95
- spawn extension add https://github.com/noant/spawn-ext-spectask --branch main
96
- ```
97
-
98
- Maintain installed packs:
99
-
100
- ```bash
101
- spawn extension list
102
- spawn extension update spectask
103
- spawn extension reinstall spectask
104
- spawn extension remove spectask
105
- spawn extension healthcheck spectask
106
- ```
107
-
108
- Authoring helpers (run inside or next to an extension project):
109
-
110
- ```bash
111
- spawn extension init ./my-ext --name my-ext
112
- spawn extension check ./my-ext
113
- spawn extension check ./my-ext --strict
114
- spawn extension from-rules ./repo-with-spawn-rules --name my-ext --output ./out
115
- ```
116
-
117
- ### Navigation from repo rules
118
-
119
- After editing files under `spawn/rules/`, refresh mandatory reads in `spawn/navigation.yaml`:
120
-
121
- ```bash
122
- spawn rules refresh
123
- ```
124
-
125
- ### Batch install from a build manifest
126
-
127
- `spawn build list` / `spawn build install` take a **build source** (positional argument; there is no implicit default):
128
-
129
- - **Local directory** whose root contains **`extensions.yaml`**. Spawn resolves the path (e.g. `.` → current working directory) and reads **`<that-directory>/extensions.yaml`** — not a path to the YAML file itself.
130
- - Otherwise a **Git URL**, **ZIP URL**, or **local path** to a repository tree: Spawn stages it, then looks for **`extensions.yaml`** at that root or, if there is exactly one top-level subdirectory, under that folder (`extensions.yaml not found` if neither applies).
131
-
132
- Each manifest entry is an extension source; optional per-entry `branch` overrides the CLI default for that row.
133
-
134
- Minimal `extensions.yaml`:
135
-
136
- ```yaml
137
- extensions:
138
- - path: https://github.com/org/extension-one.git
139
- branch: main
140
- - path: https://github.com/org/extension-two.git
141
- ```
142
-
143
- Dry-run (prints resolved entries as YAML), then install:
144
-
145
- ```bash
146
- # Manifest at ./extensions.yaml (cwd is usually your initialized target repo if you keep it there)
147
- spawn build list .
148
- spawn build install .
149
-
150
- spawn build install /path/to/methodology-bundle
151
- spawn build install https://github.com/org/team-methodology.git --branch main
152
- ```
153
-
154
- The **`--branch`** flag applies when the **build source** is Git (clone revision). Entries that omit `branch` fall back to that value.
155
-
156
- ### Example extension
157
-
158
- [spawn-ext-spectask](https://github.com/noant/spawn-ext-spectask) is a concrete extension you can install with `spawn extension add` as shown above.
159
-
160
- ---
161
-
162
- - **Python:** 3.10+ (see `pyproject.toml`).
163
- - **Deep dives:** [spec/design/user-guide.md](spec/design/user-guide.md) and [spec/design/utility.md](spec/design/utility.md).
164
-
165
- ## How to create an extension
166
-
167
- An extension can be a **full** AIDD methodology, **team** conventions (review rules, codestyle), **scaffolds** for projects that default to AIDD-friendly layouts, **skill-only** bundles, or anything else you can express as declarative files plus optional setup hooks—anything that fits the `extsrc/` layout described in the author guide.
168
-
169
- **Bootstrap with the creator extension** (install like any other extension after `spawn init`):
170
-
171
- ```bash
172
- spawn extension add https://github.com/noant/spawn-ext-creator
173
- ```
174
-
175
- **Scaffold an empty extension** with the CLI (requires `spawn init` in the repo you run from — same as other subcommands). This lays out `extsrc/` with a starter `config.yaml`, plus empty `skills/`, `files/`, and `setup/`:
176
-
177
- ```bash
178
- spawn extension init --name my-extension
179
- spawn extension init ./my-extension --name my-extension
180
- ```
181
-
182
- **Agent-guided scaffold** with **[spawn-ext-creator](https://github.com/noant/spawn-ext-creator)** (install the extension above, then `spawn ide add <ide>` so skills render into your IDE): invoke the **`spawn-ext-bootstrap`** skill so the agent lays out a fuller extension repo than the bare CLI skeleton—for example:
183
-
184
- > Use the **spawn-ext-bootstrap** skill to bootstrap a new Spawn extension with stable id `my-extension` under `./my-extension`.
185
-
186
- Other creator skills (declaring `config.yaml`, skill sources, MCP, verification, etc.) ship under the same extension; see the rendered skill list after install.
187
-
188
- Read **[spec/design/extension-author-guide.md](spec/design/extension-author-guide.md)** for the full model: required `extsrc/config.yaml`, mapping files under `extsrc/files/`, optional `skills/`, `mcp.json`, `agent-ignore`, `setup/` scripts, and how static vs artifact content is updated on `spawn extension update`.
189
-
190
- **Minimal mental model:**
191
-
192
- - `**extsrc/config.yaml`** — `schema`, `version`, stable `**name`** (install path `spawn/.extend/<name>/`), plus `files`, `skills`, ignores, optional `hints`, etc.
193
- - `**extsrc/files/**` — template tree mirrored into the target repo according to `files:` entries.
194
- - `**spawn extension check . --strict**` — validate before publishing or tagging a release.
195
-
196
- ## How to add rules without creating an extension
197
-
198
- Project-local conventions can live under **`spawn/rules/`** without packaging them as an extension. After **`spawn init`**, add any files there (for example `spawn/rules/team.md`); Spawn discovers **every file** under that directory tree.
199
-
200
- Wire those paths into **`spawn/navigation.yaml`** so mandatory reads stay aligned with what is on disk:
201
-
202
- ```bash
203
- spawn rules refresh
204
- ```
205
-
206
- That rescans **`spawn/rules/`**, attaches missing rule files under a **`rules`** group inside **`read-required`** (default description **`Local rule file.`** until you edit it), and drops stale entries whose files were deleted (you may see a warning).
207
-
208
- Rule files can be **mandatory** (**`read-required`**) or **contextual** (**`read-contextual`**). **`spawn rules refresh`** only auto-adds **new** paths into **`read-required` → `rules`**. To keep a rule **contextual**, declare it under **`read-contextual` → `rules`** in **`spawn/navigation.yaml`** with the same shape (`path`, `description`)—once a path appears in either rules list, refresh will not duplicate it into the other tier. You can move entries between **`read-required`** and **`read-contextual`** by editing **`spawn/navigation.yaml`**, then run **`spawn rules refresh`** so both lists stay consistent with files on disk.
209
-
210
- Extension-backed reads (`ext:` entries) are unrelated—you only maintain **`spawn/rules/**`** plus **`spawn rules refresh`** for repo-local rules.
211
-
212
- ## License
213
-
214
- MIT — see [LICENSE](LICENSE).
1
+ ## What is Spawn?
2
+
3
+ Spawn is a framework for building **AIDD** (AI-driven development) methodologies. It supports both **authoring** methodologies and **applying** them in a project. Within a single repository you can use **several** AIDD methodologies in a coherent way—shared navigation, skills, rules, and tooling stay aligned instead of competing ad hoc setups.
4
+
5
+ ## What is spawn-cli?
6
+
7
+ **spawn-cli** is the utility that manages methodologies installed in your project. In Spawn terminology those packs are **extensions**: versioned content that usually lives in a **Git** repository. The CLI **instantiates** instruction files, process descriptions, rules, agent skills, and wires their behavior together (navigation, IDE-facing outputs, optional lifecycle hooks). Extensions can also declare **MCP servers**, **agent-ignore** patterns, **git-ignore** entries, and similar integration points—see [`spec/design/extension-author-guide.md`](spec/design/extension-author-guide.md).
8
+
9
+ ### How spawn-cli keeps methodologies coherent
10
+
11
+ Several methodologies in one repo stay aligned because Spawn maintains **one shared navigation index**: [`spawn/navigation.yaml`](spec/design/data-structure.md) aggregates mandatory and contextual reads from **every installed extension** plus local [`spawn/rules/`](spec/design/user-guide.md) (refreshed with `spawn rules refresh`). Agents are steered through that file instead of chasing disconnected README fragments.
12
+
13
+ On each install or refresh, the CLI **regenerates IDE-facing artifacts** so skills and entry points stay consistent across extensions: rendered skill bodies include **paths and descriptions** wired from navigation (required reads, contextual hints, rule files), MCP snippets normalize server definitions per IDE adapter, and ignore lists merge without manual copy-paste. The net effect is that methodology files, generated skill links, and repo rules **compose** rather than contradict each other. Optional `hints` add short reminders to rendered skills and the Spawn-managed entry block.
14
+
15
+ **Example:** [**spawn-ext-spectask**](https://github.com/noant/spawn-ext-spectask) (Spec-Tasks methodology: spec layout, skills, design index) and [**spawn-ext-creator**](https://github.com/noant/spawn-ext-creator) (authoring flows, including agent-guided extension bootstrap) can be installed in the **same** repository and still share that single index and merged IDE outputs.
16
+
17
+ ## How to install spawn-cli
18
+
19
+ **Recommended:** install `spawn` on your `PATH` with **uv**:
20
+
21
+ ```bash
22
+ uv tool install spawn-cli && spawn --help
23
+ ```
24
+
25
+ Run once without installing (ephemeral **uvx**):
26
+
27
+ ```bash
28
+ uvx --from spawn-cli spawn --help
29
+ ```
30
+
31
+ **Upgrade** the persistent uv tool:
32
+
33
+ ```bash
34
+ uv tool upgrade spawn-cli && spawn --help
35
+ ```
36
+
37
+ Force a fresh resolver for a one-shot run:
38
+
39
+ ```bash
40
+ uvx --refresh --from spawn-cli spawn --help
41
+ ```
42
+
43
+ Additional installers (**pip**, **pipx**, local checkout) and upgrade notes: **[spec/design/user-guide.md](spec/design/user-guide.md#other-installation-options)**.
44
+
45
+ ## How spawn-cli works
46
+
47
+ Run commands from the **root of the repository** you are configuring. Almost every command requires `spawn init` first (it creates the `spawn/` tree). Only one Spawn process should touch a repo at a time (file lock).
48
+
49
+ ### Initialize a repo
50
+
51
+ ```bash
52
+ spawn init
53
+ ```
54
+
55
+ ### IDE adapters
56
+
57
+ For each **supported IDE** adapter, show whether it **looks used in the current repository** and what it can render (e.g. skills, MCP, agent-ignore):
58
+
59
+ ```bash
60
+ spawn ide list-supported-ides
61
+ ```
62
+
63
+ Register or drop IDE keys for **this** repo (examples: `cursor`, `codex`):
64
+
65
+ ```bash
66
+ spawn ide add cursor
67
+ spawn ide add cursor codex
68
+ spawn ide remove codex
69
+ spawn ide list
70
+ ```
71
+
72
+ ### Extensions
73
+
74
+ Add from a Git URL, optional branch (also supports ZIP paths and local directories/archives):
75
+
76
+ ```bash
77
+ spawn extension add https://github.com/noant/spawn-ext-spectask
78
+ spawn extension add https://github.com/noant/spawn-ext-spectask --branch main
79
+ ```
80
+
81
+ Maintain installed packs:
82
+
83
+ ```bash
84
+ spawn extension list
85
+ spawn extension update spectask
86
+ spawn extension reinstall spectask
87
+ spawn extension remove spectask
88
+ spawn extension healthcheck spectask
89
+ ```
90
+
91
+ Authoring helpers (run inside or next to an extension project):
92
+
93
+ ```bash
94
+ spawn extension init ./my-ext --name my-ext
95
+ spawn extension check ./my-ext
96
+ spawn extension check ./my-ext --strict
97
+ spawn extension from-rules ./repo-with-spawn-rules --name my-ext --output ./out
98
+ ```
99
+
100
+ ### Navigation from repo rules
101
+
102
+ After editing files under `spawn/rules/`, refresh mandatory reads in `spawn/navigation.yaml`:
103
+
104
+ ```bash
105
+ spawn rules refresh
106
+ ```
107
+
108
+ ### Batch install from a build manifest
109
+
110
+ `spawn build list` / `spawn build install` take a **build source** (positional argument; there is no implicit default):
111
+
112
+ - **Local directory** whose root contains **`extensions.yaml`**. Spawn resolves the path (e.g. `.` → current working directory) and reads **`<that-directory>/extensions.yaml`** — not a path to the YAML file itself.
113
+ - Otherwise a **Git URL**, **ZIP URL**, or **local path** to a repository tree: Spawn stages it, then looks for **`extensions.yaml`** at that root or, if there is exactly one top-level subdirectory, under that folder (`extensions.yaml not found` if neither applies).
114
+
115
+ Each manifest entry is an extension source; optional per-entry `branch` overrides the CLI default for that row.
116
+
117
+ Minimal `extensions.yaml`:
118
+
119
+ ```yaml
120
+ extensions:
121
+ - path: https://github.com/org/extension-one.git
122
+ branch: main
123
+ - path: https://github.com/org/extension-two.git
124
+ ```
125
+
126
+ Dry-run (prints resolved entries as YAML), then install:
127
+
128
+ ```bash
129
+ # Manifest at ./extensions.yaml (cwd is usually your initialized target repo if you keep it there)
130
+ spawn build list .
131
+ spawn build install .
132
+
133
+ spawn build install /path/to/methodology-bundle
134
+ spawn build install https://github.com/org/team-methodology.git --branch main
135
+ ```
136
+
137
+ The **`--branch`** flag applies when the **build source** is Git (clone revision). Entries that omit `branch` fall back to that value.
138
+
139
+ ### Example extension
140
+
141
+ [spawn-ext-spectask](https://github.com/noant/spawn-ext-spectask) is a concrete extension you can install with `spawn extension add` as shown above.
142
+
143
+ ---
144
+
145
+ - **Python:** 3.10+ (see `pyproject.toml`).
146
+ - **Deep dives:** [spec/design/user-guide.md](spec/design/user-guide.md) and [spec/design/utility.md](spec/design/utility.md).
147
+
148
+ ## How to create an extension
149
+
150
+ An extension can be a **full** AIDD methodology, **team** conventions (review rules, codestyle), **scaffolds** for projects that default to AIDD-friendly layouts, **skill-only** bundles, or anything else you can express as declarative files plus optional setup hooks—anything that fits the `extsrc/` layout described in the author guide.
151
+
152
+ **Bootstrap with the creator extension** (install like any other extension after `spawn init`):
153
+
154
+ ```bash
155
+ spawn extension add https://github.com/noant/spawn-ext-creator
156
+ ```
157
+
158
+ **Scaffold an empty extension** with the CLI (requires `spawn init` in the repo you run from — same as other subcommands). This lays out `extsrc/` with a starter `config.yaml`, plus empty `skills/`, `files/`, and `setup/`:
159
+
160
+ ```bash
161
+ spawn extension init --name my-extension
162
+ spawn extension init ./my-extension --name my-extension
163
+ ```
164
+
165
+ **Agent-guided scaffold** with **[spawn-ext-creator](https://github.com/noant/spawn-ext-creator)** (install the extension above, then `spawn ide add <ide>` so skills render into your IDE): invoke the **`spawn-ext-bootstrap`** skill so the agent lays out a fuller extension repo than the bare CLI skeleton—for example:
166
+
167
+ > Use the **spawn-ext-bootstrap** skill to bootstrap a new Spawn extension.
168
+
169
+ Other creator skills (declaring `config.yaml`, skill sources, MCP, verification, etc.) ship under the same extension; see the rendered skill list after install.
170
+
171
+ Read **[spec/design/extension-author-guide.md](spec/design/extension-author-guide.md)** for the full model: required `extsrc/config.yaml`, mapping files under `extsrc/files/`, optional `skills/`, `mcp.json`, `agent-ignore`, `setup/` scripts, and how static vs artifact content is updated on `spawn extension update`.
172
+
173
+ **Minimal mental model:**
174
+
175
+ - `extsrc/config.yaml` — `schema`, `version`, stable `name` (install path `spawn/.extend/<name>/`), plus `files`, `skills`, ignores, optional `hints`, etc.
176
+ - `extsrc/files/` — template tree mirrored into the target repo according to `files:` entries.
177
+ - `spawn extension check . --strict` — validate before publishing or tagging a release.
178
+
179
+ ## How to add rules without creating an extension
180
+
181
+ You can steer agents in two complementary ways that do **not** require an extension: **rule files** under **`spawn/rules/`** (content the agent must or may read), and **short hints** in **`spawn/navigation.yaml`** (reminders merged into rendered skills and IDE entry-point blocks such as **`AGENTS.md`**).
182
+
183
+ **After edits** to **`spawn/rules/**` or to rule rows / **`hint`** in **`spawn/navigation.yaml`**, run **`spawn refresh`** so navigation, skills, and entry points stay in sync. **`spawn rules refresh`** only syncs **`spawn/rules/**` into **`navigation.yaml`**—no skill or entry-point updates.
184
+
185
+ ### 1. Rule files
186
+
187
+ Project-local conventions live as files under **`spawn/rules/`**. After **`spawn init`**, add any files there (for example **`spawn/rules/team.md`**); Spawn discovers **every file** under that directory tree.
188
+
189
+ Wire those paths into **`spawn/navigation.yaml`** so reads stay aligned with what is on disk:
190
+
191
+ ```bash
192
+ spawn refresh
193
+ ```
194
+
195
+ That rescans **`spawn/rules/`**, attaches missing rule files under a **`rules`** group inside **`read-required`** (default description **`Local rule file.`** until you edit it), and drops stale entries whose files were deleted (you may see a warning).
196
+
197
+ **Tiers:** list a rule under **`read-required` → `rules`** (always read) or **`read-contextual` → `rules`** (read when relevant). Use the same row shape (`path`, `description`). A path must not appear in both lists—after you move a row, rerun **`spawn refresh`** (or **`spawn rules refresh`** if you only need YAML). New files discovered on disk are appended to **`read-required` → `rules`** until you relocate them.
198
+
199
+ **Extension reads:** **`ext:`** blocks are unrelated; repo-local rule paths live only under **`spawn/rules/**`** and the **`rules`** groups in **`spawn/navigation.yaml`**.
200
+
201
+ ### 2. Hints in `spawn/navigation.yaml`
202
+
203
+ For **short, always-visible reminders** (tone, language, repo-specific habits), add an optional **`hint`** field on rows under **`read-required` → `rules`**—alongside **`path`** and **`description`**.
204
+
205
+ Spawn merges those strings into the **Hints** section of **rendered skills** and into the **Hints** rollup in managed IDE entry points (for example **`AGENTS.md`**), using the same ordering and deduping rules as extension **`hints.global`**.
206
+
207
+ Example:
208
+
209
+ ```yaml
210
+ read-required:
211
+ - rules:
212
+ - path: spawn/rules/team.md
213
+ description: Team conventions.
214
+ hint: Prefer British spelling in user-facing copy.
215
+ ```
216
+
217
+ Then run **`spawn refresh`** so skills and entry points pick up the hint.
218
+
219
+ ## License
220
+
221
+ MIT — see [LICENSE](LICENSE).
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "spawn-cli"
7
- version = "0.1.10"
7
+ version = "0.1.12"
8
8
  description = "A minimal installable Python CLI package."
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.10"
@@ -66,6 +66,7 @@ def _run_script(
66
66
  target_root: Path,
67
67
  extension: str,
68
68
  script_filename: str,
69
+ phase: str,
69
70
  *,
70
71
  ext_layout: Path,
71
72
  blocking: bool,
@@ -83,6 +84,10 @@ def _run_script(
83
84
  env["SPAWN_EXT_PATH"] = str(ext_layout.resolve())
84
85
  env["SPAWN_EXT_VERSION"] = ext_ver
85
86
  env["SPAWN_TARGET_VERSION"] = tgt_ver
87
+ print(
88
+ f"spawn: running {phase} script: {Path(script_filename).name}",
89
+ file=sys.stderr,
90
+ )
86
91
  proc = subprocess.run(
87
92
  [sys.executable, str(script_path)],
88
93
  cwd=str(target_root),
@@ -110,6 +115,7 @@ def run_before_install_scripts(target_root: Path, extension: str, *, ext_layout:
110
115
  target_root,
111
116
  extension,
112
117
  cfg.setup.before_install,
118
+ "before-install",
113
119
  ext_layout=layout,
114
120
  blocking=True,
115
121
  )
@@ -124,6 +130,7 @@ def run_after_install_scripts(target_root: Path, extension: str, *, ext_layout:
124
130
  target_root,
125
131
  extension,
126
132
  cfg.setup.after_install,
133
+ "after-install",
127
134
  ext_layout=layout,
128
135
  blocking=False,
129
136
  )
@@ -140,6 +147,7 @@ def run_before_uninstall_scripts(target_root: Path, extension: str, *, ext_layou
140
147
  target_root,
141
148
  extension,
142
149
  cfg.setup.before_uninstall,
150
+ "before-uninstall",
143
151
  ext_layout=layout,
144
152
  blocking=True,
145
153
  )
@@ -156,6 +164,7 @@ def run_after_uninstall_scripts(target_root: Path, extension: str, *, ext_layout
156
164
  target_root,
157
165
  extension,
158
166
  cfg.setup.after_uninstall,
167
+ "after-uninstall",
159
168
  ext_layout=layout,
160
169
  blocking=False,
161
170
  )
@@ -191,6 +200,10 @@ def run_after_uninstall_from_snapshot(
191
200
  env["SPAWN_EXT_PATH"] = str(ghost_ext.resolve())
192
201
  env["SPAWN_EXT_VERSION"] = snap.ext_version
193
202
  env["SPAWN_TARGET_VERSION"] = _core_version(target_root)
203
+ print(
204
+ f"spawn: running after-uninstall script: {snap.script_path.name}",
205
+ file=sys.stderr,
206
+ )
194
207
  proc = subprocess.run(
195
208
  [sys.executable, str(snap.script_path)],
196
209
  cwd=str(target_root),
@@ -211,6 +224,10 @@ def run_healthcheck_scripts(target_root: Path, extension: str, *, ext_layout: Pa
211
224
  cfg = _extension_config_at(layout)
212
225
  if not cfg.setup or not cfg.setup.healthcheck:
213
226
  return True
227
+ print(
228
+ f"spawn: running healthcheck script: {Path(cfg.setup.healthcheck).name}",
229
+ file=sys.stderr,
230
+ )
214
231
  proc = subprocess.run(
215
232
  [
216
233
  sys.executable,
@@ -17,7 +17,9 @@ def spawn_lock(target_root: Path):
17
17
  try:
18
18
  lock.acquire(timeout=0)
19
19
  except Timeout:
20
- raise SpawnError("Операция в процессе (файл lock detected)") from None
20
+ raise SpawnError(
21
+ "Another Spawn operation is in progress (repository lock held)"
22
+ ) from None
21
23
  try:
22
24
  yield
23
25
  finally: