fluxflow-cli 2.11.5 → 2.11.6

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.
Files changed (2) hide show
  1. package/dist/fluxflow.js +6 -4
  2. package/package.json +1 -1
package/dist/fluxflow.js CHANGED
@@ -5023,9 +5023,10 @@ ${lines.map((l, i) => `${i + 1} | ${l}`).join("\n")}
5023
5023
  }
5024
5024
  const strip = (t) => t.replace(/^```[\w]*\n?/, "").replace(/```\s*$/, "").replace(/\r\n/g, "\n").replace(/\r/g, "\n");
5025
5025
  const processedContent = strip(content);
5026
- const lineCount = processedContent.split(/\r?\n/).length;
5027
- const originalSize = Buffer.byteLength(processedContent, "utf8");
5028
- fs10.writeFileSync(absolutePath, processedContent, "utf8");
5026
+ const finalContent = processedContent.endsWith("\n") ? processedContent : processedContent + "\n";
5027
+ const lineCount = finalContent.split(/\r?\n/).length;
5028
+ const originalSize = Buffer.byteLength(finalContent, "utf8");
5029
+ fs10.writeFileSync(absolutePath, finalContent, "utf8");
5029
5030
  let verifiedContent = fs10.readFileSync(absolutePath, "utf8");
5030
5031
  const verifiedSize = Buffer.byteLength(verifiedContent, "utf8");
5031
5032
  const verifiedLines = verifiedContent.split(/\r?\n/);
@@ -9571,7 +9572,8 @@ ${boxBottom}` };
9571
9572
  diffOpened = true;
9572
9573
  await new Promise((r) => setTimeout(r, 50));
9573
9574
  } else if (normToolName === "write_file") {
9574
- const modifiedContent = toolArgs.content || toolArgs.newContent || "";
9575
+ const rawContent = toolArgs.content || toolArgs.newContent || "";
9576
+ const modifiedContent = rawContent.endsWith("\n") ? rawContent : rawContent + "\n";
9575
9577
  if (!fs20.existsSync(absPath)) {
9576
9578
  isNewFileCreated = true;
9577
9579
  fs20.mkdirSync(path19.dirname(absPath), { recursive: true });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fluxflow-cli",
3
- "version": "2.11.5",
3
+ "version": "2.11.6",
4
4
  "date": "2026-06-23",
5
5
  "description": "A high-fidelity agentic terminal assistant for the Flux Era.",
6
6
  "keywords": [