codebakers 2.5.3 → 2.5.4
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 +5 -5
- package/package.json +1 -1
- package/src/index.ts +1 -1
- package/src/patterns/loader.ts +1 -1
package/dist/index.js
CHANGED
|
@@ -1499,7 +1499,7 @@ import Anthropic from "@anthropic-ai/sdk";
|
|
|
1499
1499
|
import { execa as execa5 } from "execa";
|
|
1500
1500
|
|
|
1501
1501
|
// src/patterns/loader.ts
|
|
1502
|
-
import
|
|
1502
|
+
import fs2 from "fs-extra";
|
|
1503
1503
|
import * as path2 from "path";
|
|
1504
1504
|
var CORE_PATTERNS = `
|
|
1505
1505
|
# CODEBAKERS CORE PATTERNS
|
|
@@ -2392,7 +2392,7 @@ async function readClipboard() {
|
|
|
2392
2392
|
return null;
|
|
2393
2393
|
}
|
|
2394
2394
|
}
|
|
2395
|
-
async function
|
|
2395
|
+
async function readFile(filePath) {
|
|
2396
2396
|
try {
|
|
2397
2397
|
let cleanPath = filePath.trim();
|
|
2398
2398
|
if (cleanPath.startsWith('"') && cleanPath.endsWith('"') || cleanPath.startsWith("'") && cleanPath.endsWith("'")) {
|
|
@@ -2709,7 +2709,7 @@ async function codeCommand(prompt, options = {}) {
|
|
|
2709
2709
|
\u{1F4CB} Read ${clipContent.length} characters from clipboard
|
|
2710
2710
|
`));
|
|
2711
2711
|
if (await fs6.pathExists(clipContent.trim())) {
|
|
2712
|
-
const file = await
|
|
2712
|
+
const file = await readFile(clipContent.trim());
|
|
2713
2713
|
if (file) {
|
|
2714
2714
|
fileContext = formatFilesForContext([file]);
|
|
2715
2715
|
console.log(chalk6.green(`\u{1F4C4} Loaded file: ${file.name}
|
|
@@ -2761,7 +2761,7 @@ ${clipContent}
|
|
|
2761
2761
|
continue;
|
|
2762
2762
|
}
|
|
2763
2763
|
} else if (await fs6.pathExists(userInput)) {
|
|
2764
|
-
const file = await
|
|
2764
|
+
const file = await readFile(userInput);
|
|
2765
2765
|
if (file) {
|
|
2766
2766
|
fileContext = formatFilesForContext([file]);
|
|
2767
2767
|
console.log(chalk6.green(`
|
|
@@ -8110,7 +8110,7 @@ If unclear between multiple commands, use the most likely one with lower confide
|
|
|
8110
8110
|
}
|
|
8111
8111
|
|
|
8112
8112
|
// src/index.ts
|
|
8113
|
-
var VERSION = "2.5.
|
|
8113
|
+
var VERSION = "2.5.4";
|
|
8114
8114
|
async function showMainMenu() {
|
|
8115
8115
|
const config = new Config();
|
|
8116
8116
|
console.clear();
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
package/src/patterns/loader.ts
CHANGED