@vibgrate/cli 2026.722.1 → 2026.722.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/baseline-BD3A7EXD.js +7 -0
- package/dist/{baseline-J44M7MWP.js.map → baseline-BD3A7EXD.js.map} +1 -1
- package/dist/{chunk-XKXKWYJF.js → chunk-2O5YZVZV.js} +4 -4
- package/dist/{chunk-XKXKWYJF.js.map → chunk-2O5YZVZV.js.map} +1 -1
- package/dist/{chunk-VXT6LUGP.js → chunk-3MXNNBLI.js} +3 -3
- package/dist/{chunk-VXT6LUGP.js.map → chunk-3MXNNBLI.js.map} +1 -1
- package/dist/{chunk-JSNHZCIV.js → chunk-5BDHQ7DD.js} +3 -3
- package/dist/{chunk-JSNHZCIV.js.map → chunk-5BDHQ7DD.js.map} +1 -1
- package/dist/{chunk-2EVQKZTO.js → chunk-I7GY7MVN.js} +143 -6
- package/dist/chunk-I7GY7MVN.js.map +1 -0
- package/dist/{chunk-EXQV26MF.js → chunk-NONYJLOJ.js} +3 -3
- package/dist/{chunk-EXQV26MF.js.map → chunk-NONYJLOJ.js.map} +1 -1
- package/dist/cli.js +52 -9
- package/dist/cli.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +3 -3
- package/dist/{interactive-736PBC7J.js → interactive-A4DISSIW.js} +8 -147
- package/dist/interactive-A4DISSIW.js.map +1 -0
- package/package.json +1 -1
- package/dist/baseline-J44M7MWP.js +0 -7
- package/dist/chunk-2EVQKZTO.js.map +0 -1
- package/dist/interactive-736PBC7J.js.map +0 -1
package/dist/cli.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { sha256Hex, generateKeypair, dssePae, DSSE_PAYLOAD_TYPE, keyId, registerBuild, readGlobal, applyGlobalOptions, ProgressBar, printLogo, resolveProviders, runBuild } from './chunk-
|
|
3
|
-
export { runBuild } from './chunk-
|
|
4
|
-
import { loadAdvancedScanHook, baselineCommand } from './chunk-
|
|
5
|
-
import { serveStdio, exportGraph, GraphSource, createServer, formatForExt } from './chunk-
|
|
6
|
-
import { resolveDsn, resolveIngestHost, dashHostForIngestHost, resolveCliInvocation, availableRegionIds, createWorkspaceDsn, writeStoredCredentials, credentialsPath, findGitRoot, ensureGitignored, gitignoreEntryForCredentials, clearStoredCredentials, CliError, ExitCode, parseDsn as parseDsn$1, uploadScanArtifact, ingestHostForRegionId, dsnCommand, pushCommand, NPX_INVOCATION, refreshIfStale, driftCount, countTokens, shortestPath, renderReport, testsToRun, detectRunner, defaultGraphPath, ASSISTANTS, detectAssistants, usageError, loadGraph, detectServeLaunch, installAssistant, writeNavigationConfig, uninstallAssistant, coveringTests, FREE_PACK, readScanArtifact, discoverModels, buildGraph, writeArtifacts, writeSnapshot, probeFreshness, discover, vibgrateDir, assistantById, SMALL_REPO_FILES, resolveLimits, publishPrivateLibrary, assessDocQuality, symbolsFromApi, fetchHostedDocsCached, selectForBudget, hostedBase, readStoredCredentials, projectCredentialsPath, homeCredentialsPath, SKIP_DIRS, SKIP_FILES } from './chunk-
|
|
2
|
+
import { sha256Hex, generateKeypair, dssePae, DSSE_PAYLOAD_TYPE, keyId, registerBuild, readGlobal, applyGlobalOptions, ProgressBar, printLogo, fetchCatalog, resolveProviders, runBuild } from './chunk-I7GY7MVN.js';
|
|
3
|
+
export { runBuild } from './chunk-I7GY7MVN.js';
|
|
4
|
+
import { loadAdvancedScanHook, baselineCommand } from './chunk-NONYJLOJ.js';
|
|
5
|
+
import { serveStdio, exportGraph, GraphSource, createServer, formatForExt } from './chunk-2O5YZVZV.js';
|
|
6
|
+
import { resolveDsn, resolveIngestHost, dashHostForIngestHost, resolveCliInvocation, availableRegionIds, createWorkspaceDsn, writeStoredCredentials, credentialsPath, findGitRoot, ensureGitignored, gitignoreEntryForCredentials, clearStoredCredentials, CliError, ExitCode, parseDsn as parseDsn$1, uploadScanArtifact, ingestHostForRegionId, dsnCommand, pushCommand, NPX_INVOCATION, refreshIfStale, driftCount, countTokens, shortestPath, renderReport, testsToRun, detectRunner, defaultGraphPath, ASSISTANTS, detectAssistants, usageError, loadGraph, detectServeLaunch, installAssistant, writeNavigationConfig, uninstallAssistant, coveringTests, FREE_PACK, readScanArtifact, discoverModels, buildGraph, writeArtifacts, writeSnapshot, probeFreshness, discover, vibgrateDir, assistantById, SMALL_REPO_FILES, resolveLimits, publishPrivateLibrary, assessDocQuality, symbolsFromApi, fetchHostedDocsCached, selectForBudget, hostedBase, readStoredCredentials, projectCredentialsPath, homeCredentialsPath, SKIP_DIRS, SKIP_FILES } from './chunk-3MXNNBLI.js';
|
|
7
7
|
import { inventory, resolveOne, enrichOnline, ECOSYSTEMS, catalogPath, libDir, loadCatalog, driftFor, addLibrary, resolveLib, libId, resolveVersion, readDoc, localPackageDocs, localApiSurface } from './chunk-GGJZA3Q6.js';
|
|
8
|
-
import { writeDefaultConfig, parseDsn, detectVcs, computeRepoFingerprint, resolveRepositoryName, fetchScanPreflight, runCoreScan, VERSION, loadConfig, prepareCompressedUpload, computeDriftScore, titleBox, projectTypeToVulnEcosystem, driftBar, gitHistoryAvailable, buildVersionTimelines, findPackageAnyEcosystem, normalizeConstraint, findVersionCrossings, versionSatisfies, PROJECT_TYPE_TO_OSV_ECOSYSTEM, fetchRiskySymbols } from './chunk-
|
|
8
|
+
import { writeDefaultConfig, parseDsn, detectVcs, computeRepoFingerprint, resolveRepositoryName, fetchScanPreflight, runCoreScan, VERSION, loadConfig, prepareCompressedUpload, computeDriftScore, titleBox, projectTypeToVulnEcosystem, driftBar, gitHistoryAvailable, buildVersionTimelines, findPackageAnyEcosystem, normalizeConstraint, findVersionCrossings, versionSatisfies, PROJECT_TYPE_TO_OSV_ECOSYSTEM, fetchRiskySymbols } from './chunk-5BDHQ7DD.js';
|
|
9
9
|
import { resolvedGrammarFiles, grammarSetVersion } from './chunk-PY3DNX5H.js';
|
|
10
10
|
import './chunk-RXP66R2E.js';
|
|
11
11
|
import { pathExists as pathExists$1, parseExcludePatterns } from './chunk-GI6W53LM.js';
|
|
@@ -3469,6 +3469,49 @@ function registerModels(program) {
|
|
|
3469
3469
|
else info(c.green(` \u2714 pulled ${name} \u2014 use it with \`vg code --provider ollama --model ${name}\``));
|
|
3470
3470
|
});
|
|
3471
3471
|
applyGlobalOptions(pull);
|
|
3472
|
+
const rm = cmd.command("rm").description("remove a locally-installed model via your runtime (Ollama) \u2014 requires --yes; nothing is removed by default").argument("<name>", "installed model name, e.g. qwen2.5-coder:7b").option("--runtime <id>", "runtime to remove from (default: ollama)", "ollama").option("--yes", "actually remove (without this it only prints the plan \u2014 nothing is removed by default)").action(function(name, opts) {
|
|
3473
|
+
const global = readGlobal(this);
|
|
3474
|
+
if (opts.runtime !== "ollama") {
|
|
3475
|
+
throw new CliError(`only the ollama runtime supports rm today (got --runtime ${opts.runtime}). LM Studio / gguf models are managed in their own apps.`, ExitCode.USAGE_ERROR);
|
|
3476
|
+
}
|
|
3477
|
+
const plan = { runtime: "ollama", command: `ollama rm ${name}`, willRemove: !!opts.yes };
|
|
3478
|
+
if (!opts.yes) {
|
|
3479
|
+
if (global.json) json({ ...plan, note: "dry-run \u2014 re-run with --yes to remove (nothing is removed by default)" });
|
|
3480
|
+
else {
|
|
3481
|
+
info(`${c.cyan("vg models rm")} \xB7 would run: ${c.bold(plan.command)}`);
|
|
3482
|
+
info(c.dim(" nothing is removed by default \u2014 re-run with --yes to actually remove it"));
|
|
3483
|
+
}
|
|
3484
|
+
return;
|
|
3485
|
+
}
|
|
3486
|
+
if (!hasBinary("ollama")) {
|
|
3487
|
+
throw new CliError("ollama is not installed or not on PATH \u2014 install it from https://ollama.com, then re-run.", ExitCode.NOT_FOUND);
|
|
3488
|
+
}
|
|
3489
|
+
if (!global.json) info(c.dim(` $ ${plan.command}`));
|
|
3490
|
+
const res = spawnSync("ollama", ["rm", name], { stdio: global.json ? "ignore" : "inherit" });
|
|
3491
|
+
if (res.status !== 0) {
|
|
3492
|
+
throw new CliError(`\`ollama rm ${name}\` failed (exit ${res.status ?? "signal"}) \u2014 check the model name with \`vg models\`.`, ExitCode.ERROR);
|
|
3493
|
+
}
|
|
3494
|
+
if (global.json) json({ ...plan, removed: true });
|
|
3495
|
+
else info(c.green(` \u2714 removed ${name}`));
|
|
3496
|
+
});
|
|
3497
|
+
applyGlobalOptions(rm);
|
|
3498
|
+
const catalog = cmd.command("catalog").description("the live hosted model catalog (OpenRouter) \u2014 key-free, cached, refreshed from the network").option("--offline", "never touch the network \u2014 use the cache (or the curated fallback)").option("--refresh", "bypass the cache and refresh from the network").action(async function(opts) {
|
|
3499
|
+
const global = readGlobal(this);
|
|
3500
|
+
const cat = await fetchCatalog({ offline: opts.offline, noCache: opts.refresh });
|
|
3501
|
+
if (global.json) {
|
|
3502
|
+
json(cat);
|
|
3503
|
+
return;
|
|
3504
|
+
}
|
|
3505
|
+
const count = cat.providers.reduce((n, p) => n + p.models.length, 0);
|
|
3506
|
+
info(`${c.cyan("vg models catalog")} \xB7 ${count} model(s) across ${cat.providers.length} provider(s) \xB7 ${c.dim(cat.source)}`);
|
|
3507
|
+
for (const p of cat.providers) {
|
|
3508
|
+
info(` ${c.bold(p.label)} ${c.dim(`(${p.models.length})`)}`);
|
|
3509
|
+
for (const m of p.models.slice(0, 8)) info(` ${m.id}`);
|
|
3510
|
+
if (p.models.length > 8) info(c.dim(` \u2026and ${p.models.length - 8} more`));
|
|
3511
|
+
}
|
|
3512
|
+
info(c.dim(" use one with `vg code --provider openrouter --model <id>` (needs OPENROUTER_API_KEY)"));
|
|
3513
|
+
});
|
|
3514
|
+
applyGlobalOptions(catalog);
|
|
3472
3515
|
}
|
|
3473
3516
|
function hasBinary(bin) {
|
|
3474
3517
|
const probe = spawnSync(process.platform === "win32" ? "where" : "which", [bin], { stdio: "ignore" });
|
|
@@ -3569,7 +3612,7 @@ function registerCode(program) {
|
|
|
3569
3612
|
if (!(process.stdin.isTTY && process.stdout.isTTY)) {
|
|
3570
3613
|
throw usageError('say what to change, e.g. `vg code "add a --timeout flag to the scan command"` (guided mode needs an interactive terminal)');
|
|
3571
3614
|
}
|
|
3572
|
-
const { runInteractive } = await import('./interactive-
|
|
3615
|
+
const { runInteractive } = await import('./interactive-A4DISSIW.js');
|
|
3573
3616
|
await runInteractive(
|
|
3574
3617
|
rootOf(global),
|
|
3575
3618
|
global,
|
|
@@ -3670,7 +3713,7 @@ ${res.stderr}` : ""), exitCode: res.status ?? 1 };
|
|
|
3670
3713
|
if (!autonomous && !tty) {
|
|
3671
3714
|
throw usageError("the agent approves each edit/command \u2014 run in a terminal to approve interactively, or pass --auto to run autonomously (or --single for a one-shot diff).");
|
|
3672
3715
|
}
|
|
3673
|
-
const { agentTask } = await import('./interactive-
|
|
3716
|
+
const { agentTask } = await import('./interactive-A4DISSIW.js');
|
|
3674
3717
|
const { nodeCodeFs } = await import('./session-POJUDFPH.js');
|
|
3675
3718
|
const { TtyPrompter } = await import('./ui-HOVOPWMX.js');
|
|
3676
3719
|
let priorSummary;
|
|
@@ -4294,7 +4337,7 @@ var initCommand = new Command("init").description("Initialize vibgrate in a proj
|
|
|
4294
4337
|
console.log(chalk7.green("\u2714") + ` Created ${chalk7.bold("vibgrate.config.ts")}`);
|
|
4295
4338
|
}
|
|
4296
4339
|
if (opts.baseline) {
|
|
4297
|
-
const { runBaseline } = await import('./baseline-
|
|
4340
|
+
const { runBaseline } = await import('./baseline-BD3A7EXD.js');
|
|
4298
4341
|
await runBaseline(rootDir);
|
|
4299
4342
|
}
|
|
4300
4343
|
console.log("");
|