fix(coding-agent): honor PI_PACKAGE_DIR for bun asset paths closes #3074

This commit is contained in:
Mario Zechner
2026-04-17 00:38:34 +02:00
parent 8404fbafdb
commit e5f86f25f2
2 changed files with 4 additions and 3 deletions

View File

@@ -110,7 +110,7 @@ export function getPackageDir(): string {
*/
export function getThemesDir(): string {
if (isBunBinary) {
return join(dirname(process.execPath), "theme");
return join(getPackageDir(), "theme");
}
// Theme is in modes/interactive/theme/ relative to src/ or dist/
const packageDir = getPackageDir();
@@ -126,7 +126,7 @@ export function getThemesDir(): string {
*/
export function getExportTemplateDir(): string {
if (isBunBinary) {
return join(dirname(process.execPath), "export-html");
return join(getPackageDir(), "export-html");
}
const packageDir = getPackageDir();
const srcOrDist = existsSync(join(packageDir, "src")) ? "src" : "dist";
@@ -166,7 +166,7 @@ export function getChangelogPath(): string {
*/
export function getInteractiveAssetsDir(): string {
if (isBunBinary) {
return join(dirname(process.execPath), "assets");
return join(getPackageDir(), "assets");
}
const packageDir = getPackageDir();
const srcOrDist = existsSync(join(packageDir, "src")) ? "src" : "dist";