mirror of
https://github.com/NeuralNomadsAI/CodeNomad.git
synced 2026-07-10 00:14:27 +00:00
Ensure build script runs from package root
This commit is contained in:
parent
2c46b7476b
commit
8858fe052b
1 changed files with 4 additions and 1 deletions
|
|
@ -4,6 +4,9 @@ import { $ } from "bun"
|
|||
import { existsSync } from "fs"
|
||||
import { join } from "path"
|
||||
|
||||
const appDir = join(import.meta.dir, "..")
|
||||
$.cwd(appDir)
|
||||
|
||||
const platforms = {
|
||||
mac: {
|
||||
args: ["--mac", "--x64", "--arm64", "--universal"],
|
||||
|
|
@ -58,7 +61,7 @@ async function build(platform: string) {
|
|||
await $`bun run build`
|
||||
|
||||
console.log("\n📦 Step 2/2: Packaging binaries...\n")
|
||||
const distExists = existsSync(join(process.cwd(), "dist"))
|
||||
const distExists = existsSync(join(appDir, "dist"))
|
||||
if (!distExists) {
|
||||
throw new Error("dist/ directory not found. Build failed.")
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue