You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: dev/build/ProjectInstructions/PROJECT_INSTRUCTIONS_VERSION.md
+2-1Lines changed: 2 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# Project Instructions Version
2
2
3
-
Current Project Instructions Version: 2026.06.28.017
3
+
Current Project Instructions Version: 2026.06.28.018
4
4
5
5
Last Updated: 2026-06-28
6
6
@@ -25,6 +25,7 @@ Last Updated: 2026-06-28
25
25
- Added root leftover audit and `src/` transition plan for the final repository layout cleanup stage.
26
26
- Removed safe empty local root directory shells and documented blocked local-only `assets/` cleanup.
27
27
- Removed the local demo `.gfsp` artifact and recorded a file-by-file `src/` destination audit for future scoped migrations.
28
+
- Moved PR017-audited browser/www-owned legacy `src/` files into `www/src/` while preserving public `/src/...` browser route compatibility under the `www` web root.
28
29
- Codex must read this version file and the latest repository copy of `PROJECT_INSTRUCTIONS.md` before performing work.
29
30
- Codex must discard previously remembered Project Instructions and treat the repository copy as authoritative.
30
31
- Codex must validate canonical report and ZIP paths, branching model, and legacy path avoidance before work proceeds.
Copy file name to clipboardExpand all lines: dev/build/ProjectInstructions/repository/canonical_repository_structure.md
+25-17Lines changed: 25 additions & 17 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ Valid top-level folders:
14
14
- www/
15
15
16
16
Root product and repo sections:
17
-
- www/ owns browser-served production website sections, Creator toolbox pages, public game discovery, production Docs & Help, and browser assets.
17
+
- www/ owns browser-served production website sections, Creator toolbox pages, public game discovery, production Docs & Help, browser assets, and browser-owned runtime/client modules under `www/src/`.
18
18
- api/ is the Node/API/server application surface for server entry points, API routing, API services, database access, storage access, auth, setup, publishing, and admin server logic.
- src/web/ owns browser-facing deployable application modules used by public pages, account/admin surfaces, and Creator tools.
31
-
-src/api-runtime/ owns deployable API/runtime service modules that back the shared Browser -> API -> Postgres/R2 contract.
32
-
-src/runtime/ owns deployable game, tool, engine, and shared runtime capabilities.
33
-
- Existing top-level src/advanced/, src/api/, src/engine/, src/shared/, and src/tools/ directories are legacy transition buckets until explicit migration PRs move them.
29
+
Final source ownership after the repository layout simplification:
30
+
-`www/src/` owns browser-facing deployable application modules used by public pages, account/admin surfaces, Creator tools, game runtime, shared browser utilities, and browser API clients.
31
+
-`api/` owns deployable API/runtime service modules that back the shared Browser -> API -> Postgres/R2 contract.
32
+
-`dev/` owns developer-only source, scripts, tests, reports, local runtime orchestration, and reference material.
33
+
- Existing root `src/shared/contracts/`, `src/shared/schemas/`, `src/shared/projectDataStore/`, and source-reference files are legacy transition buckets until explicit migration PRs move them.
34
34
- Browser API clients remain outside `api/`; browser-served code must use API/service contracts instead of importing top-level `api/` files directly.
35
-
-`src/dev-runtime/admin/`remains only as a legacy Admin Notes browser-viewer compatibility path until a scoped browser admin migration retires it.
36
-
- Do not add new top-level src/ layer names outside src/web/, src/api-runtime/, or src/runtime/ without OWNER approval.
35
+
-`www/src/dev-runtime/admin/`preserves the public `/src/dev-runtime/admin/...`Admin Notes browser-viewer compatibility route under the `www` web root.
36
+
- Do not add new root `src/` layer names or new root `src/` work without OWNER approval.
37
37
- Do not use team names in runtime source filenames.
These legacy transition buckets may remain until explicit migration PRs move them into `src/web/`, `src/api-runtime/`, or `src/runtime/`.
81
+
- www/src/advanced/
82
+
- www/src/api/
83
+
- www/src/engine/
84
+
- www/src/shared/
85
+
- www/src/tools/
86
+
- www/src/dev-runtime/admin/
87
+
- src/shared/contracts/
88
+
- src/shared/schemas/
89
+
- src/shared/projectDataStore/
90
+
- src/dev-runtime/admin/.gitkeep
91
+
92
+
The `www/src/` legacy transition buckets preserve public `/src/...` browser import compatibility during source retirement. Remaining root `src/` buckets may remain only until explicit stacked migration PRs move them to `api/` or `dev/`.
86
93
87
94
## Rules
88
95
@@ -102,7 +109,8 @@ These legacy transition buckets may remain until explicit migration PRs move the
102
109
- Do not create new folders unless they fit the documented canonical structure.
103
110
- If a requested or generated path does not clearly fit the canonical structure, Codex must HARD STOP and report the proposed path.
104
111
- New development follows the canonical structure.
105
-
- New deployable `src/` work follows `src/web/`, `src/api-runtime/`, or `src/runtime/`.
112
+
- New browser-owned source belongs under `www/` according to the browser source and asset rules above.
113
+
- New API/server source belongs under `api/`.
106
114
- New non-deployable work belongs under `dev/`.
107
115
- Required reports belong under flat `dev/reports/`.
108
116
- Required ZIPs belong under `dev/workspace/zips/`; generated temporary artifacts belong under `dev/workspace/tmp/`.
@@ -15,9 +15,11 @@ This map began as a no-runtime-change governance artifact. `PR_26180_OWNER_008-m
15
15
16
16
The browser-served application now lives under `www/`.
17
17
18
+
PR_26180_OWNER_018 moved the PR017-audited browser/www-owned legacy `src/` files into `www/src/`.
19
+
18
20
Current local runtime, test helpers, and browser pages keep URLs such as `/index.html`, `/toolbox/index.html`, `/assets/theme-v2/css/theme.css`, `/account/sign-in.html`, `/admin/system-health.html`, and `/games/index.html` while resolving browser-served files from `www/`.
19
21
20
-
The move preserved public route URLs while changing the filesystem lookup root. Repository-root fallback remains available for transition-only compatibility, including browser imports that still reference root-level `src/`.
22
+
The move preserved public route URLs while changing the filesystem lookup root. Browser imports that use `/src/...` or relative paths resolving to `/src/...` now resolve under `www/src/` when `www/` is the served web root.
21
23
22
24
## Current Browser-Served Surface
23
25
@@ -54,7 +56,7 @@ Broad active-reference search across browser roots, `src/`, `dev/scripts/`, and
54
56
|`legal/`| 13 | Footer/navigation route references and page links. |
55
57
|`learn/`| 9 | Learn route links and navigation. |
56
58
|`play/`| 7 | No root folder exists; review references manually before introducing a route. |
57
-
|`src/`| 451 | Browser imports, server imports, tests, validation aliases, and current runtime/source modules. |
59
+
|`src/`| 451 | Browser imports, server imports, tests, validation aliases, and legacy runtime/source modules before the browser-owned subset moved to `www/src/`. |
58
60
59
61
The high `src/` count means the browser migration cannot be treated as static files only. Several browser-facing pages import modules from root-level `src/`, including account/admin/toolbox flows.
60
62
@@ -103,7 +105,7 @@ Examples of current references that depend on root-level path relationships:
103
105
-`toolbox/toolRegistry.js` imports from `../src/shared/toolbox/tool-metadata-inventory.js`.
104
106
-`assets/toolbox/*/js/index.js` imports from `../../../../src/` or `../../../../toolbox/` in several tool flows.
105
107
106
-
These references can be preserved temporarily by serving compatibility paths from the repository root, but the final architecture should move browser-facing runtime modules into`www/` or an approved deployable browser module surface.
108
+
These references are preserved by serving the browser-owned source modules from`www/src/` while keeping public `/src/...` URL compatibility.
0 commit comments