kodingo-cli 1.0.14 → 1.0.16
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.
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.inferDecisionSummary = inferDecisionSummary;
|
|
4
4
|
exports.inferMemoryFromCode = inferMemoryFromCode;
|
|
5
|
-
const KODINGO_API_URL = process.env.KODINGO_API_URL ?? "https://
|
|
5
|
+
const KODINGO_API_URL = process.env.KODINGO_API_URL ?? "https://api.kodingo.xyz";
|
|
6
6
|
async function inferDecisionSummary(input) {
|
|
7
7
|
try {
|
|
8
8
|
const code = input.diff.slice(0, 2000);
|
package/dist/commands/init.js
CHANGED
|
@@ -52,7 +52,7 @@ const path = __importStar(require("path"));
|
|
|
52
52
|
const os = __importStar(require("os"));
|
|
53
53
|
const open_1 = __importDefault(require("open"));
|
|
54
54
|
const persistence_config_1 = require("../utils/persistence-config");
|
|
55
|
-
const API_BASE = "https://
|
|
55
|
+
const API_BASE = "https://api.kodingo.xyz";
|
|
56
56
|
const APP_URL = "https://kodingo.xyz";
|
|
57
57
|
const CONFIG_DIR = path.join(os.homedir(), ".kodingo");
|
|
58
58
|
const AUTH_TOKEN_PATH = path.join(CONFIG_DIR, "auth.json");
|
|
@@ -113,7 +113,7 @@ function ensureGitignoreEntry(repoRoot, entry) {
|
|
|
113
113
|
}
|
|
114
114
|
}
|
|
115
115
|
// ── Browser login flow ────────────────────────────────────────────────────────
|
|
116
|
-
async function browserLogin() {
|
|
116
|
+
async function browserLogin(rl) {
|
|
117
117
|
// Request a state token from the API
|
|
118
118
|
const initRes = await fetch(`${API_BASE}/cli/auth/init`, { method: "POST" });
|
|
119
119
|
if (!initRes.ok)
|
|
@@ -122,8 +122,7 @@ async function browserLogin() {
|
|
|
122
122
|
console.log("\nPress Enter to open kodingo.xyz in your browser...");
|
|
123
123
|
console.log(`Or open this URL manually: ${loginUrl}\n`);
|
|
124
124
|
await new Promise(resolve => {
|
|
125
|
-
|
|
126
|
-
rl.question("", () => { rl.close(); resolve(); });
|
|
125
|
+
rl.question("", () => resolve());
|
|
127
126
|
});
|
|
128
127
|
// Open browser
|
|
129
128
|
try {
|
|
@@ -191,7 +190,7 @@ function registerInitCommand(program) {
|
|
|
191
190
|
}
|
|
192
191
|
else {
|
|
193
192
|
console.log("\nKodingo — Connect this repository\n");
|
|
194
|
-
const result = await browserLogin();
|
|
193
|
+
const result = await browserLogin(rl);
|
|
195
194
|
authToken = result.token;
|
|
196
195
|
email = result.email;
|
|
197
196
|
saveAuthToken(authToken, email);
|
|
@@ -20,7 +20,7 @@ exports.scanRepoCommand = scanRepoCommand;
|
|
|
20
20
|
const fs_1 = __importDefault(require("fs"));
|
|
21
21
|
const path_1 = __importDefault(require("path"));
|
|
22
22
|
const persistence_config_1 = require("../utils/persistence-config");
|
|
23
|
-
const API_BASE = "https://
|
|
23
|
+
const API_BASE = "https://api.kodingo.xyz";
|
|
24
24
|
const SUPPORTED_EXTENSIONS = [
|
|
25
25
|
".ts", ".tsx", ".js", ".jsx",
|
|
26
26
|
".py", ".go", ".rs", ".php",
|