@n-dream/builders-cli 0.2.2 → 0.2.4

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
@@ -41,7 +41,38 @@ direct. The connection to the local dev server never uses the proxy.
41
41
  It connects again by itself when the connection breaks. It stops when the
42
42
  token is not valid, or when a newer tunnel for the same work takes over.
43
43
 
44
- ## Keep the session awake
44
+ ## Dev server and test data (`--dev`)
45
+
46
+ With `--dev`, the command also runs the app's dev server
47
+ (`pnpm dev --port <port>`) in the current folder, and starts it again
48
+ when it stops. It also runs the Firebase emulators (Firestore and
49
+ Storage) for the app's test data:
50
+
51
+ - They need Java 21 or later. Without it, the command tells you what to
52
+ install, and the app shows the same message.
53
+ - The first start installs firebase-tools in `~/.builders/firebase-tools/`
54
+ and takes about 30 seconds. The package has a lock file for it: every
55
+ package has a fixed version and checksum, and no install script runs.
56
+ Later starts take about 15 seconds.
57
+ - The data is in `.builders-dev/emulators/` in the app folder. Git does
58
+ not see it. The command saves it every 30 seconds and when it stops,
59
+ and loads it at the next start. If the machine stops hard, the changes
60
+ of the last 30 seconds can be lost. If the emulators cannot load the
61
+ saved data (3 failed starts, a start without it works, and one more
62
+ start with it fails), they start empty, and the old data stays in
63
+ `.builders-dev/emulators/export-bad-<time>/`.
64
+ - The emulator files (about 180 MB) download once per machine, before
65
+ the first start.
66
+ - The dev server gets `FIRESTORE_EMULATOR_HOST`,
67
+ `FIREBASE_STORAGE_EMULATOR_HOST`, `STORAGE_EMULATOR_HOST`,
68
+ `GOOGLE_CLOUD_PROJECT` (`demo-builders`, no Google credentials needed)
69
+ and, with the storage add-on, `STORAGE_BUCKET`.
70
+ - Emulators that an earlier run left behind are stopped at the next
71
+ start, after their data is saved.
72
+ - When an emulator does not answer two checks in a row (30 seconds
73
+ apart), the command starts the emulators again.
74
+
75
+ ## Keep the preview awake
45
76
 
46
77
  ```
47
78
  npx -y @n-dream/builders-cli awake --token-file <file> [--again] [--idle-minutes 15] [--max-minutes 25]