@mean-weasel/lineage 0.1.10 → 0.1.11
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/CHANGELOG.md +6 -0
- package/README.md +11 -2
- package/dist/cli/lineage-dev.js +36 -12
- package/dist/cli/lineage-dev.js.map +3 -3
- package/dist/cli/lineage.js +36 -12
- package/dist/cli/lineage.js.map +3 -3
- package/dist/server.js +12 -10
- package/dist/server.js.map +3 -3
- package/dist/web/assets/{index-CICrfv4C.js → index-ADWhXN3-.js} +1 -1
- package/dist/web/index.html +1 -1
- package/package.json +1 -1
package/dist/server.js
CHANGED
|
@@ -290,7 +290,7 @@ function nowIso() {
|
|
|
290
290
|
return (/* @__PURE__ */ new Date()).toISOString();
|
|
291
291
|
}
|
|
292
292
|
function lineageDbPath() {
|
|
293
|
-
return process.env.LINEAGE_DB || join3(
|
|
293
|
+
return process.env.LINEAGE_DB || join3(packageRoot, ".lineage", "asset-lineage.sqlite");
|
|
294
294
|
}
|
|
295
295
|
function lineageDb() {
|
|
296
296
|
mkdirSync2(join3(lineageDbPath(), ".."), { recursive: true });
|
|
@@ -1140,7 +1140,7 @@ function isPackageRoot(path) {
|
|
|
1140
1140
|
return false;
|
|
1141
1141
|
}
|
|
1142
1142
|
}
|
|
1143
|
-
function
|
|
1143
|
+
function resolvePackageRoot() {
|
|
1144
1144
|
const moduleDir = dirname2(fileURLToPath(import.meta.url));
|
|
1145
1145
|
const candidates = [
|
|
1146
1146
|
process.env.LINEAGE_REPO_ROOT,
|
|
@@ -1152,7 +1152,8 @@ function resolveRepoRoot() {
|
|
|
1152
1152
|
if (!root) throw new Error("Unable to locate Lineage package root");
|
|
1153
1153
|
return root;
|
|
1154
1154
|
}
|
|
1155
|
-
var
|
|
1155
|
+
var packageRoot = resolvePackageRoot();
|
|
1156
|
+
var repoRoot = resolve2(process.env.LINEAGE_ASSET_ROOT || packageRoot);
|
|
1156
1157
|
var defaultProject = "demo-project";
|
|
1157
1158
|
var defaultProduct = process.env.LINEAGE_DEFAULT_PRODUCT || defaultProject;
|
|
1158
1159
|
var publicFallbackBucket = "lineage-demo-assets";
|
|
@@ -1181,7 +1182,7 @@ function catalogPath(project = defaultProject) {
|
|
|
1181
1182
|
return join4(repoRoot, cleanProject(project), "assets", "catalog.json");
|
|
1182
1183
|
}
|
|
1183
1184
|
function fixtureCatalogPath(project = defaultProject) {
|
|
1184
|
-
return join4(
|
|
1185
|
+
return join4(packageRoot, "fixtures", cleanProject(project), "assets", "catalog.json");
|
|
1185
1186
|
}
|
|
1186
1187
|
function resolvedCatalogPath(project = defaultProject) {
|
|
1187
1188
|
const path = catalogPath(project);
|
|
@@ -6424,7 +6425,7 @@ import { gunzipSync } from "node:zlib";
|
|
|
6424
6425
|
var demoWorkspaceTitle = "Demo: Content iteration tree";
|
|
6425
6426
|
var demoWorkspaceNotes = "Repeatable sample lineage for demos and onboarding. Archive it when reviewing real work.";
|
|
6426
6427
|
var demoBasePath = ["lineage-demo", "2026-06-lineage-demo"];
|
|
6427
|
-
var swissifierManifestPath = join8(
|
|
6428
|
+
var swissifierManifestPath = join8(packageRoot, "fixtures", defaultProject, "lineage", "swissifier-rich-demo.json");
|
|
6428
6429
|
var demoAssets = [
|
|
6429
6430
|
{ key: "root", channel: "linkedin", file: "demo-root.svg", label: "Initial Demo Concept", fill: "#f6fbfb", stroke: "#0b7f88" },
|
|
6430
6431
|
{ key: "hookA", channel: "tiktok", file: "demo-hook-a-v01.svg", label: "Hook A v01", fill: "#fff8e6", stroke: "#9a6a00" },
|
|
@@ -7196,7 +7197,7 @@ import { join as join9 } from "node:path";
|
|
|
7196
7197
|
var require3 = createRequire2(import.meta.url);
|
|
7197
7198
|
function packageInfo() {
|
|
7198
7199
|
try {
|
|
7199
|
-
const info = JSON.parse(readFileSync5(join9(
|
|
7200
|
+
const info = JSON.parse(readFileSync5(join9(packageRoot, "package.json"), "utf8"));
|
|
7200
7201
|
return { name: info.name || "@mean-weasel/lineage", version: info.version || "0.0.0" };
|
|
7201
7202
|
} catch {
|
|
7202
7203
|
return { name: "@mean-weasel/lineage", version: "0.0.0" };
|
|
@@ -7212,8 +7213,8 @@ function normalizeRuntimeChannel(value) {
|
|
|
7212
7213
|
function gitSha() {
|
|
7213
7214
|
const envSha = process.env.LINEAGE_GIT_SHA || process.env.GITHUB_SHA;
|
|
7214
7215
|
if (envSha) return envSha.slice(0, 40);
|
|
7215
|
-
if (!existsSync6(join9(
|
|
7216
|
-
const result = spawnSync2("git", ["rev-parse", "--short=12", "HEAD"], { cwd:
|
|
7216
|
+
if (!existsSync6(join9(packageRoot, ".git"))) return void 0;
|
|
7217
|
+
const result = spawnSync2("git", ["rev-parse", "--short=12", "HEAD"], { cwd: packageRoot, encoding: "utf8" });
|
|
7217
7218
|
return result.status === 0 ? result.stdout.trim() || void 0 : void 0;
|
|
7218
7219
|
}
|
|
7219
7220
|
function tableExists(database, table) {
|
|
@@ -7246,6 +7247,7 @@ function getLineageRuntimeInfo(options = {}) {
|
|
|
7246
7247
|
}
|
|
7247
7248
|
}
|
|
7248
7249
|
return {
|
|
7250
|
+
asset_root: repoRoot,
|
|
7249
7251
|
channel: normalizeRuntimeChannel(options.channel || process.env.LINEAGE_CHANNEL || process.env.LINEAGE_RELEASE_CHANNEL),
|
|
7250
7252
|
database: databaseInfo,
|
|
7251
7253
|
fetchedAt: nowIso(),
|
|
@@ -7599,7 +7601,7 @@ app.post(
|
|
|
7599
7601
|
})
|
|
7600
7602
|
);
|
|
7601
7603
|
if (isProduction) {
|
|
7602
|
-
const dist = join10(
|
|
7604
|
+
const dist = join10(packageRoot, "dist", "web");
|
|
7603
7605
|
if (existsSync7(dist)) {
|
|
7604
7606
|
app.use(express2.static(dist));
|
|
7605
7607
|
app.get("*", (_req, res) => res.sendFile(join10(dist, "index.html")));
|
|
@@ -7608,7 +7610,7 @@ if (isProduction) {
|
|
|
7608
7610
|
const { createServer: createViteServer } = await import("vite");
|
|
7609
7611
|
const e2ePort = process.env.LINEAGE_E2E_PORT ? Number(process.env.LINEAGE_E2E_PORT) : void 0;
|
|
7610
7612
|
const vite = await createViteServer({
|
|
7611
|
-
configFile: join10(
|
|
7613
|
+
configFile: join10(packageRoot, "vite.config.ts"),
|
|
7612
7614
|
server: {
|
|
7613
7615
|
middlewareMode: true,
|
|
7614
7616
|
...e2ePort ? { ws: { port: e2ePort + 1e3 } } : {}
|