@pulse-editor/cli 0.1.12 → 0.1.13
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.
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { existsSync, writeFileSync } from "fs";
|
|
1
|
+
import { existsSync, mkdirSync, writeFileSync } from "fs";
|
|
2
2
|
import fs from "fs/promises";
|
|
3
3
|
import { globSync } from "glob";
|
|
4
4
|
import { networkInterfaces } from "os";
|
|
@@ -374,10 +374,15 @@ export function compileAppActionSkills(pulseConfig) {
|
|
|
374
374
|
}
|
|
375
375
|
// Generate tsconfig for server functions
|
|
376
376
|
export function generateTempTsConfig() {
|
|
377
|
-
const
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
377
|
+
const tempTsConfigDir = path.join(process.cwd(), "node_modules/.pulse");
|
|
378
|
+
const tempTsConfigPath = path.join(tempTsConfigDir, "tsconfig.server.json");
|
|
379
|
+
// Always regenerate: the previous implementation skipped regeneration when
|
|
380
|
+
// the file existed, but the tsconfig bakes in absolute paths derived from
|
|
381
|
+
// process.cwd(). If the project is moved/renamed (or was generated from a
|
|
382
|
+
// different parent dir) the stale cache causes ts-loader TS18003 errors.
|
|
383
|
+
// Ensure the parent directory exists so we don't ENOENT on fresh installs
|
|
384
|
+
// or when `.pulse` has been wiped.
|
|
385
|
+
mkdirSync(tempTsConfigDir, { recursive: true });
|
|
381
386
|
const tsConfig = {
|
|
382
387
|
compilerOptions: {
|
|
383
388
|
target: "ES2020",
|