@basou/cli 0.51.0 → 0.53.0
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/dist/index.js +9 -9
- package/dist/index.js.map +1 -1
- package/dist/program.js +9 -9
- package/dist/program.js.map +1 -1
- package/package.json +2 -2
package/dist/program.js
CHANGED
|
@@ -725,8 +725,8 @@ ${block}${markers.end}
|
|
|
725
725
|
return `${section.before}${markers.start}
|
|
726
726
|
${block}${markers.end}${section.after}`;
|
|
727
727
|
case "no_markers": {
|
|
728
|
-
const
|
|
729
|
-
return `${existing}${
|
|
728
|
+
const sep4 = existing.endsWith("\n\n") ? "" : existing.endsWith("\n") ? "\n" : "\n\n";
|
|
729
|
+
return `${existing}${sep4}${wrapped}`;
|
|
730
730
|
}
|
|
731
731
|
default:
|
|
732
732
|
throw new Error(
|
|
@@ -5786,9 +5786,9 @@ function applyGitignorePlan(repositoryRoot, plan) {
|
|
|
5786
5786
|
throw new Error("Failed to read .gitignore", { cause: error });
|
|
5787
5787
|
}
|
|
5788
5788
|
}
|
|
5789
|
-
const
|
|
5789
|
+
const sep4 = existing.length > 0 && !existing.endsWith("\n") ? "\n" : "";
|
|
5790
5790
|
try {
|
|
5791
|
-
writeFileSync(file, `${existing}${
|
|
5791
|
+
writeFileSync(file, `${existing}${sep4}${plan.toAdd.join("\n")}
|
|
5792
5792
|
`);
|
|
5793
5793
|
} catch (error) {
|
|
5794
5794
|
throw new Error("Failed to write .gitignore", { cause: error });
|
|
@@ -9916,7 +9916,7 @@ async function noteCodexHookStatusPreSpawn(_cwd, ctx) {
|
|
|
9916
9916
|
|
|
9917
9917
|
// src/commands/session.ts
|
|
9918
9918
|
import { readFile as readFile7 } from "fs/promises";
|
|
9919
|
-
import { basename as basename7, isAbsolute as isAbsolute6, join as join15, relative as relative3 } from "path";
|
|
9919
|
+
import { basename as basename7, isAbsolute as isAbsolute6, join as join15, relative as relative3, sep as sep2 } from "path";
|
|
9920
9920
|
import {
|
|
9921
9921
|
acquireLock as acquireLock6,
|
|
9922
9922
|
appendEventToExistingSession as appendEventToExistingSession3,
|
|
@@ -10186,7 +10186,7 @@ function formatWorkingDir(workingDir, repositoryRoot, options) {
|
|
|
10186
10186
|
if (workingDir === repositoryRoot) return "<repository_root>";
|
|
10187
10187
|
const rel = relative3(repositoryRoot, workingDir);
|
|
10188
10188
|
if (rel.length === 0 || rel === ".") return "<repository_root>";
|
|
10189
|
-
if (rel.startsWith(
|
|
10189
|
+
if (rel === ".." || rel.startsWith(`..${sep2}`)) return rel;
|
|
10190
10190
|
return `./${rel}`;
|
|
10191
10191
|
}
|
|
10192
10192
|
function formatRelatedFiles(files) {
|
|
@@ -12376,7 +12376,7 @@ function inertLines(result) {
|
|
|
12376
12376
|
// src/lib/portfolio-safety.ts
|
|
12377
12377
|
import { execFile as execFile2 } from "child_process";
|
|
12378
12378
|
import { lstat as lstat2, realpath as realpath4 } from "fs/promises";
|
|
12379
|
-
import { isAbsolute as isAbsolute7, join as join18, relative as relative4, resolve as resolve11 } from "path";
|
|
12379
|
+
import { isAbsolute as isAbsolute7, join as join18, relative as relative4, resolve as resolve11, sep as sep3 } from "path";
|
|
12380
12380
|
import { promisify as promisify2 } from "util";
|
|
12381
12381
|
import { readManifest as readManifest15 } from "@basou/core";
|
|
12382
12382
|
var execFileAsync2 = promisify2(execFile2);
|
|
@@ -12392,7 +12392,7 @@ async function canonical(p) {
|
|
|
12392
12392
|
}
|
|
12393
12393
|
function isInside(child, parent) {
|
|
12394
12394
|
const rel = relative4(parent, child);
|
|
12395
|
-
return rel === "" || !rel.startsWith(
|
|
12395
|
+
return rel === "" || rel !== ".." && !rel.startsWith(`..${sep3}`) && !isAbsolute7(rel);
|
|
12396
12396
|
}
|
|
12397
12397
|
function isBasouPath(p) {
|
|
12398
12398
|
return p === ".basou" || p.startsWith(".basou/") || p.includes("/.basou/") || p.endsWith("/.basou");
|
|
@@ -14015,7 +14015,7 @@ async function assertWorkspaceInitialized15(basouRoot) {
|
|
|
14015
14015
|
function readBuildStamp() {
|
|
14016
14016
|
if (false) return void 0;
|
|
14017
14017
|
try {
|
|
14018
|
-
return JSON.parse('{"version":"0.
|
|
14018
|
+
return JSON.parse('{"version":"0.53.0","commit":"b27ba83","committedAt":"2026-09-25T17:22:51+09:00"}');
|
|
14019
14019
|
} catch {
|
|
14020
14020
|
return void 0;
|
|
14021
14021
|
}
|