From 02e96d49be7578ec171905b4f6dad7a52e817022 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Sat, 14 Feb 2026 14:16:44 +0000 Subject: [PATCH] Refactor magic number 30078 to KIND_APP_DATA constant - Added KIND_APP_DATA to src/constants.mjs - Updated src/lib.mjs, src/lock-ops.mjs, and dashboard/index.html to use the constant - Added missing src files to package.json files list - Updated build.mjs to copy src/constants.mjs to dist/src/ Co-authored-by: PR0M3TH3AN <53631862+PR0M3TH3AN@users.noreply.github.com> --- build.mjs | 4 ++++ dashboard/index.html | 4 +++- package.json | 5 +++++ src/constants.mjs | 1 + src/lib.mjs | 3 ++- src/lock-ops.mjs | 3 ++- 6 files changed, 17 insertions(+), 3 deletions(-) diff --git a/build.mjs b/build.mjs index 9261b3a..b45245e 100644 --- a/build.mjs +++ b/build.mjs @@ -9,6 +9,7 @@ const DIST_DIR = path.join(__dirname, 'dist'); const LANDING_SRC = path.join(__dirname, 'landing'); const DASHBOARD_SRC = path.join(__dirname, 'dashboard'); const DOCS_SRC = path.join(__dirname, 'src', 'docs'); +const CONSTANTS_SRC = path.join(__dirname, 'src', 'constants.mjs'); const PROMPTS_SRC = path.join(__dirname, 'src', 'prompts', 'META_PROMPTS.md'); const CONFIG_SRC = path.join(__dirname, 'torch-config.json'); const ASSETS_SRC = path.join(__dirname, 'assets'); @@ -42,6 +43,9 @@ const distDocs = path.join(DIST_DIR, 'src', 'docs'); fs.mkdirSync(distDocs, { recursive: true }); fs.cpSync(DOCS_SRC, distDocs, { recursive: true }); +// 3.5. Copy src/constants.mjs -> dist/src/constants.mjs +fs.copyFileSync(CONSTANTS_SRC, path.join(DIST_DIR, 'src', 'constants.mjs')); + // 4. Copy src/prompts/META_PROMPTS.md -> dist/src/prompts/META_PROMPTS.md const distPromptsDir = path.join(DIST_DIR, 'src', 'prompts'); fs.mkdirSync(distPromptsDir, { recursive: true }); diff --git a/dashboard/index.html b/dashboard/index.html index 3a31af8..ec38436 100644 --- a/dashboard/index.html +++ b/dashboard/index.html @@ -152,6 +152,8 @@