openclaw-aegis 1.12.1 → 1.12.2

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/cli/index.js CHANGED
@@ -2357,7 +2357,8 @@ var fs9 = __toESM(require("fs"));
2357
2357
  var path3 = __toESM(require("path"));
2358
2358
  function parseIncident(filePath) {
2359
2359
  const id = path3.basename(filePath, ".jsonl");
2360
- const lines = fs9.readFileSync(filePath, "utf-8").trim().split("\n").filter(Boolean);
2360
+ const actualFile = fs9.statSync(filePath).isDirectory() ? path3.join(filePath, "events.jsonl") : filePath;
2361
+ const lines = fs9.readFileSync(actualFile, "utf-8").trim().split("\n").filter(Boolean);
2361
2362
  const events = [];
2362
2363
  for (const line of lines) {
2363
2364
  try {
@@ -2387,7 +2388,10 @@ var incidentsCommand = new import_commander5.Command("incidents").description("B
2387
2388
  console.log("No incidents recorded yet.");
2388
2389
  return;
2389
2390
  }
2390
- const files = fs9.readdirSync(incidentsDir).filter((f) => f.endsWith(".jsonl")).sort().reverse();
2391
+ const files = fs9.readdirSync(incidentsDir).filter((f) => {
2392
+ const full = path3.join(incidentsDir, f);
2393
+ return f.endsWith(".jsonl") || fs9.statSync(full).isDirectory() && fs9.existsSync(path3.join(full, "events.jsonl"));
2394
+ }).sort().reverse();
2391
2395
  if (files.length === 0) {
2392
2396
  console.log("No incidents recorded yet.");
2393
2397
  return;