Seed files use process.cwd
This commit is contained in:
@@ -4,7 +4,7 @@
|
|||||||
"title": "Community Rule",
|
"title": "Community Rule",
|
||||||
"author": "MEDLab",
|
"author": "MEDLab",
|
||||||
"description": "Community governance and rule-building app",
|
"description": "Community governance and rule-building app",
|
||||||
"version": "0.1.3",
|
"version": "0.1.4",
|
||||||
"httpPort": 3000,
|
"httpPort": 3000,
|
||||||
"healthCheckPath": "/api/health",
|
"healthCheckPath": "/api/health",
|
||||||
"memoryLimit": 805306368,
|
"memoryLimit": 805306368,
|
||||||
|
|||||||
@@ -11,7 +11,8 @@ import {
|
|||||||
sectionFacetsSchema,
|
sectionFacetsSchema,
|
||||||
} from "../../lib/server/validation/methodFacetsSchemas";
|
} from "../../lib/server/validation/methodFacetsSchemas";
|
||||||
|
|
||||||
const REPO_ROOT = path.resolve(__dirname, "..", "..");
|
// Bundled seed runs from repo root (`process.cwd()`); __dirname breaks under esbuild.
|
||||||
|
const REPO_ROOT = process.cwd();
|
||||||
const DATA_DIR = path.join(REPO_ROOT, "data", "create", "customRule");
|
const DATA_DIR = path.join(REPO_ROOT, "data", "create", "customRule");
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ import type { PrismaClient } from "@prisma/client";
|
|||||||
import { FACET_GROUP_IDS } from "../../lib/server/validation/methodFacetsSchemas";
|
import { FACET_GROUP_IDS } from "../../lib/server/validation/methodFacetsSchemas";
|
||||||
import { templateFacetFileSchema } from "../../lib/server/validation/templateFacetSchema";
|
import { templateFacetFileSchema } from "../../lib/server/validation/templateFacetSchema";
|
||||||
|
|
||||||
const REPO_ROOT = path.resolve(__dirname, "..", "..");
|
const REPO_ROOT = process.cwd();
|
||||||
const TEMPLATE_FACET_FILE = path.join(
|
const TEMPLATE_FACET_FILE = path.join(
|
||||||
REPO_ROOT,
|
REPO_ROOT,
|
||||||
"data",
|
"data",
|
||||||
|
|||||||
Reference in New Issue
Block a user