Skip to content

Commit 445368e

Browse files
committed
docs: switch @org placeholder from @nkzw to @acme across the feature
`@nkzw` is a real GitHub/npm org (Christoph Pojer's), and seeing it in `vp create @nkzw` examples risks readers trying to run the command expecting a working picker. Swap to `@acme` — the classic placeholder-company handle already used elsewhere in the RFC — so examples read as clearly hypothetical. Touched: the RFC, docs/guide/create.md, docs/config/create.md, packages/cli/src/create/{bin.ts, define-config.ts}, all four org snap-tests, and the three org unit test specs. Four snap outputs regenerated; 263 unit tests still pass. The real dependency import in `packages/cli/src/create/random-name.ts` (`@nkzw/safe-word-list`) and the team bio in `docs/_data/team.js` are legitimate references and were left alone.
1 parent b87b4cc commit 445368e

24 files changed

Lines changed: 147 additions & 147 deletions

File tree

docs/config/create.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,12 @@ import { defineConfig } from 'vite-plus';
1111

1212
export default defineConfig({
1313
create: {
14-
defaultTemplate: '@nkzw',
14+
defaultTemplate: '@acme',
1515
},
1616
});
1717
```
1818

19-
Any value accepted by `vp create` as a first argument works here — `@nkzw` for an org picker, `@nkzw/web` for a direct manifest entry, `vite:application` for a built-in, etc.
19+
Any value accepted by `vp create` as a first argument works here — `@acme` for an org picker, `@acme/web` for a direct manifest entry, `vite:application` for a built-in, etc.
2020

2121
## Precedence
2222

docs/guide/create.md

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -94,11 +94,11 @@ An organization can publish a curated set of templates under a single npm scope
9494
### Pick from an org
9595

9696
```bash
97-
# Open an interactive picker over @nkzw/create's manifest
98-
vp create @nkzw
97+
# Open an interactive picker over @acme/create's manifest
98+
vp create @acme
9999

100100
# Run a specific manifest entry directly
101-
vp create @nkzw/web
101+
vp create @acme/web
102102

103103
# Set the org as the default for a repo (see create.defaultTemplate config)
104104
vp create
@@ -113,7 +113,7 @@ There are two common layouts. Pick the one that matches the org's template count
113113
**Bundled (recommended for most orgs).** All templates live as subdirectories of `@org/create` itself. Manifest entries use relative `./path` values. One repo, one publish, one versioning story — the same pattern used by `create-vite` and `create-next-app`.
114114

115115
```
116-
@nkzw/create/
116+
@acme/create/
117117
├── package.json # "vp": { "templates": [{ "template": "./templates/web" }, ...] }
118118
├── templates/
119119
│ ├── web/
@@ -126,8 +126,8 @@ There are two common layouts. Pick the one that matches the org's template count
126126
**Manifest-only.** When the org already publishes independent `@org/template-*` packages (or hosts them on GitHub), `@org/create` stays a thin index.
127127

128128
```
129-
@nkzw/create/
130-
├── package.json # "vp": { "templates": [{ "template": "@nkzw/template-web" }, ...] }
129+
@acme/create/
130+
├── package.json # "vp": { "templates": [{ "template": "@acme/template-web" }, ...] }
131131
└── README.md
132132
```
133133

@@ -141,20 +141,20 @@ The manifest lives at `vp.templates` in `@org/create`'s `package.json`:
141141

142142
```json
143143
{
144-
"name": "@nkzw/create",
144+
"name": "@acme/create",
145145
"version": "1.0.0",
146146
"vp": {
147147
"templates": [
148148
{
149149
"name": "monorepo",
150-
"description": "Full Nakazawa Tech monorepo",
151-
"template": "@nkzw/template-monorepo",
150+
"description": "Full Acme Corp monorepo",
151+
"template": "@acme/template-monorepo",
152152
"monorepo": true
153153
},
154154
{
155155
"name": "web",
156156
"description": "Web app template (Vite + React)",
157-
"template": "@nkzw/template-web",
157+
"template": "@acme/template-web",
158158
"keywords": ["web", "react", "app"]
159159
},
160160
{
@@ -177,7 +177,7 @@ Each entry supports:
177177
| `keywords` | no | Filter terms for picker search. |
178178
| `monorepo` | no | If `true`, marks this entry as a monorepo-creating template. Hidden from the picker when `vp create` runs inside an existing monorepo, mirroring the built-in `vite:monorepo` filter. |
179179

180-
An invalid manifest is a hard error, not a silent fall-through — a maintainer who shipped a manifest should hear about the offending field, e.g. `@nkzw/create: vp.templates[2].template must be a non-empty string`.
180+
An invalid manifest is a hard error, not a silent fall-through — a maintainer who shipped a manifest should hear about the offending field, e.g. `@acme/create: vp.templates[2].template must be a non-empty string`.
181181

182182
### Bundled subdirectory templates
183183

@@ -191,11 +191,11 @@ Commit this in `vite.config.ts` at the project root:
191191
import { defineConfig } from 'vite-plus';
192192

193193
export default defineConfig({
194-
create: { defaultTemplate: '@nkzw' },
194+
create: { defaultTemplate: '@acme' },
195195
});
196196
```
197197

198-
Now `vp create` (with no argument) drops straight into the `@nkzw` picker. See [`create.defaultTemplate`](/config/create) for details.
198+
Now `vp create` (with no argument) drops straight into the `@acme` picker. See [`create.defaultTemplate`](/config/create) for details.
199199

200200
The picker always appends a trailing **Vite+ built-in templates** entry so `vite:monorepo` / `vite:application` / `vite:library` / `vite:generator` stay reachable from the picker — selecting it routes to the standard built-in flow. For scripts and CI, explicit specifiers (`vp create vite:library`) bypass the configured default.
201201

@@ -204,16 +204,16 @@ The picker always appends a trailing **Vite+ built-in templates** entry so `vite
204204
`vp create @org --no-interactive` prints a stable, fixed-column table of the manifest (name, description, resolved template specifier) and exits 1. The output is machine-parseable, so scripts and AI agents can recover the list without a separate `--list` flag:
205205

206206
```
207-
error: vp create @nkzw requires a template selection in non-interactive mode.
207+
error: vp create @acme requires a template selection in non-interactive mode.
208208
209-
available templates from @nkzw/create:
209+
available templates from @acme/create:
210210
211211
NAME DESCRIPTION TEMPLATE
212-
web Web app template (Vite + React) @nkzw/template-web
213-
library TypeScript library template @nkzw/template-library
212+
web Web app template (Vite + React) @acme/template-web
213+
library TypeScript library template @acme/template-library
214214
demo Bundled demo template ./templates/demo
215215
216-
hint: rerun with an explicit selection, e.g. `vp create @nkzw/web`,
216+
hint: rerun with an explicit selection, e.g. `vp create @acme/web`,
217217
or use a Vite+ built-in template like `vp create vite:application`.
218218
```
219219

packages/cli/snap-tests/create-org-bundled/mock-manifest.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
{
2-
"@nkzw/create": {
3-
"name": "@nkzw/create",
2+
"@acme/create": {
3+
"name": "@acme/create",
44
"dist-tags": { "latest": "1.0.0" },
55
"versions": {
66
"1.0.0": {
77
"version": "1.0.0",
88
"dist": {
9-
"tarball": "{REGISTRY}/@nkzw/create/-/create-1.0.0.tgz",
9+
"tarball": "{REGISTRY}/@acme/create/-/create-1.0.0.tgz",
1010
"integrity": "sha512-h4Q9x+aUa2RUJGBe7JCZnWpGMyd8VHXPfL9+EBxrA2EWRV8rlmMCP45B3woZ8xA2fmkE/jUy1W7OM2GCjoPWQA=="
1111
},
1212
"vp": {

packages/cli/snap-tests/create-org-bundled/mock-server.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// Minimal mock npm registry used by `create-org-*` snap-tests.
22
//
3-
// Reads `./mock-manifest.json` (keyed by URL path, e.g. `"@nkzw/create"`) and
3+
// Reads `./mock-manifest.json` (keyed by URL path, e.g. `"@acme/create"`) and
44
// optionally serves `.tgz` tarballs from `./tarballs/<name>`. Picks an
55
// ephemeral port, sets `NPM_CONFIG_REGISTRY` on the child environment, spawns
66
// the wrapped command, and tears down when the child exits.

packages/cli/snap-tests/create-org-bundled/snap.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
1-
> node mock-server.mjs -- vp create @nkzw/demo --no-interactive --directory my-demo-app # bundled template: extract tarball, copy subdir
1+
> node mock-server.mjs -- vp create @acme/demo --no-interactive --directory my-demo-app # bundled template: extract tarball, copy subdir
22

3-
selected 'demo' from @nkzw/create
3+
selected 'demo' from @acme/create
44
◇ Scaffolded my-demo-app
55
• Node <semver> pnpm <semver>
66
→ Next: cd my-demo-app && vp run

packages/cli/snap-tests/create-org-bundled/steps.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"commands": [
3-
"node mock-server.mjs -- vp create @nkzw/demo --no-interactive --directory my-demo-app # bundled template: extract tarball, copy subdir",
3+
"node mock-server.mjs -- vp create @acme/demo --no-interactive --directory my-demo-app # bundled template: extract tarball, copy subdir",
44
"cat my-demo-app/package.json # verify package.json name was rewritten",
55
"cat my-demo-app/src/index.ts # verify bundled source copied",
66
"ls my-demo-app/README.md # verify README copied"

packages/cli/snap-tests/create-org-invalid-manifest/mock-manifest.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
{
2-
"@nkzw/create": {
3-
"name": "@nkzw/create",
2+
"@acme/create": {
3+
"name": "@acme/create",
44
"dist-tags": { "latest": "1.0.0" },
55
"versions": {
66
"1.0.0": {
77
"version": "1.0.0",
88
"dist": {
9-
"tarball": "{REGISTRY}/@nkzw/create/-/create-1.0.0.tgz",
9+
"tarball": "{REGISTRY}/@acme/create/-/create-1.0.0.tgz",
1010
"integrity": "sha512-fake"
1111
},
1212
"vp": {

packages/cli/snap-tests/create-org-invalid-manifest/mock-server.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// Minimal mock npm registry used by `create-org-*` snap-tests.
22
//
3-
// Reads `./mock-manifest.json` (keyed by URL path, e.g. `"@nkzw/create"`) and
3+
// Reads `./mock-manifest.json` (keyed by URL path, e.g. `"@acme/create"`) and
44
// optionally serves `.tgz` tarballs from `./tarballs/<name>`. Picks an
55
// ephemeral port, sets `NPM_CONFIG_REGISTRY` on the child environment, spawns
66
// the wrapped command, and tears down when the child exits.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
[1]> node mock-server.mjs -- vp create @nkzw --no-interactive # invalid manifest -> schema error
1+
[1]> node mock-server.mjs -- vp create @acme --no-interactive # invalid manifest -> schema error
22

3-
@nkzw/create: vp.templates[0].template must be a non-empty string
3+
@acme/create: vp.templates[0].template must be a non-empty string
44
Failed to resolve org template manifest
55

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
"commands": [
3-
"node mock-server.mjs -- vp create @nkzw --no-interactive # invalid manifest -> schema error"
3+
"node mock-server.mjs -- vp create @acme --no-interactive # invalid manifest -> schema error"
44
]
55
}

0 commit comments

Comments
 (0)