create-watchpot 0.0.0-stage → 1.0.0-rc.2
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 +46 -2
- package/dist/index.js +3045 -0
- package/package.json +28 -4
package/README.md
CHANGED
|
@@ -1,3 +1,47 @@
|
|
|
1
|
-
#
|
|
1
|
+
# create-watchpot
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Makes a new idle game on the watchpot engine.
|
|
4
|
+
|
|
5
|
+
```sh
|
|
6
|
+
bun create watchpot # or: npm create watchpot
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
It asks a few questions, writes the game into a new folder named after it, and installs its packages.
|
|
10
|
+
|
|
11
|
+
## The prompts
|
|
12
|
+
|
|
13
|
+
1. **Name.** The game's title (default `My Idle Game`). Its folder is the name's slug, in the current folder; a folder
|
|
14
|
+
that already holds files is refused.
|
|
15
|
+
2. **Tailwind CSS?** No by default. Yes styles the game's UI components (`src/ui/`) with Tailwind v4 utilities over the
|
|
16
|
+
`--ui-*` tokens, instead of CSS modules. The screens outside `src/ui/` keep their CSS modules.
|
|
17
|
+
3. **3D stage?** No by default. Yes adds `three` and `@react-three/fiber` to the game, at the same versions the engine
|
|
18
|
+
itself uses.
|
|
19
|
+
4. **AI agent skills?** No by default. Yes adds `AGENTS.md` and the engine's `watchpot-init` skill, then asks where:
|
|
20
|
+
`.claude/skills` (Claude Code), `.agents/skills` (Codex and others), `.cursor/skills` (Cursor). At least one.
|
|
21
|
+
|
|
22
|
+
Ctrl-C at any prompt cancels and exits 0.
|
|
23
|
+
|
|
24
|
+
## Flags
|
|
25
|
+
|
|
26
|
+
```sh
|
|
27
|
+
bun create watchpot --name "Tap Jar" --tailwind --three --skills=.claude/skills,.agents/skills --no-install --yes
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
- `--name <name>`, `--tailwind`, `--three`, `--skills=<dir,dir>`: answer that prompt with the flag, so it is not asked.
|
|
31
|
+
- `--yes`: take the default for every prompt that has no flag.
|
|
32
|
+
- `--no-install`: write the game and stop, without `bun install` (or `npm install`).
|
|
33
|
+
|
|
34
|
+
## What it does
|
|
35
|
+
|
|
36
|
+
The game is written from the engine's own template and its smallest answers fixture, with the name given. The engine is
|
|
37
|
+
the installed `watchpot` package, so the game's `watchpot` dependency is `^<the engine's version>`, from npm.
|
|
38
|
+
|
|
39
|
+
The game runs on Bun: after `cd <slug>`, `bun run dev` serves it at `http://localhost:3000`. Get Bun at https://bun.sh.
|
|
40
|
+
|
|
41
|
+
## Development
|
|
42
|
+
|
|
43
|
+
```sh
|
|
44
|
+
bun run build # bundles src/index.ts into dist/index.js (Node 20+, runs under Bun too)
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
The engine's slow test `test/tooling/create-watchpot.slow.test.ts` builds this and runs it against the checkout.
|