@vibgrate/cli 2026.806.2 → 2026.813.1
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/{agent-DSC3EQLT.js → agent-N3CP3SPI.js} +11 -11
- package/dist/{agent-DSC3EQLT.js.map → agent-N3CP3SPI.js.map} +1 -1
- package/dist/baseline-ZMRZRGFI.js +9 -0
- package/dist/{baseline-KVCXVZFQ.js.map → baseline-ZMRZRGFI.js.map} +1 -1
- package/dist/{chunk-QDKFGLI3.js → chunk-3WUTQYRY.js} +7 -7
- package/dist/{chunk-QDKFGLI3.js.map → chunk-3WUTQYRY.js.map} +1 -1
- package/dist/{chunk-D2VEJHPC.js → chunk-5JJBGBP2.js} +8 -8
- package/dist/{chunk-D2VEJHPC.js.map → chunk-5JJBGBP2.js.map} +1 -1
- package/dist/{chunk-Y4JO6LYP.js → chunk-5ROZODMW.js} +302 -11
- package/dist/chunk-5ROZODMW.js.map +1 -0
- package/dist/{chunk-ZPPDKHGL.js → chunk-6423BHLN.js} +7 -7
- package/dist/{chunk-ZPPDKHGL.js.map → chunk-6423BHLN.js.map} +1 -1
- package/dist/{chunk-455ZJQQ4.js → chunk-6GQLEDVK.js} +5 -5
- package/dist/{chunk-455ZJQQ4.js.map → chunk-6GQLEDVK.js.map} +1 -1
- package/dist/{chunk-SBVZGEOB.js → chunk-7ZHSSGUF.js} +3 -3
- package/dist/{chunk-SBVZGEOB.js.map → chunk-7ZHSSGUF.js.map} +1 -1
- package/dist/{chunk-SI4D7DYF.js → chunk-ADP6ITGF.js} +44 -8
- package/dist/chunk-ADP6ITGF.js.map +1 -0
- package/dist/{chunk-7C5UKIXD.js → chunk-CJNWHXQD.js} +12 -10
- package/dist/chunk-CJNWHXQD.js.map +1 -0
- package/dist/{chunk-ZMSTSEGR.js → chunk-EWZKOU66.js} +3 -3
- package/dist/{chunk-ZMSTSEGR.js.map → chunk-EWZKOU66.js.map} +1 -1
- package/dist/{chunk-TOVVTZTM.js → chunk-FBVKQXBH.js} +3 -3
- package/dist/{chunk-TOVVTZTM.js.map → chunk-FBVKQXBH.js.map} +1 -1
- package/dist/{chunk-HV4CKBXT.js → chunk-GOPANQZT.js} +3 -3
- package/dist/{chunk-HV4CKBXT.js.map → chunk-GOPANQZT.js.map} +1 -1
- package/dist/{chunk-6L6V77HW.js → chunk-IJQOZ6ZD.js} +8 -8
- package/dist/{chunk-6L6V77HW.js.map → chunk-IJQOZ6ZD.js.map} +1 -1
- package/dist/{chunk-VTJAPNJO.js → chunk-JYM4QT6F.js} +4 -4
- package/dist/{chunk-VTJAPNJO.js.map → chunk-JYM4QT6F.js.map} +1 -1
- package/dist/{chunk-KYRH3567.js → chunk-KBP7GJV6.js} +3 -3
- package/dist/{chunk-KYRH3567.js.map → chunk-KBP7GJV6.js.map} +1 -1
- package/dist/{chunk-6XKDAYYR.js → chunk-KF2QT6RY.js} +4 -4
- package/dist/{chunk-6XKDAYYR.js.map → chunk-KF2QT6RY.js.map} +1 -1
- package/dist/{chunk-INIULQEP.js → chunk-N6ZMZ5AI.js} +11 -2
- package/dist/chunk-N6ZMZ5AI.js.map +1 -0
- package/dist/{chunk-IQJUFRZZ.js → chunk-OYHAF2J2.js} +5 -5
- package/dist/{chunk-IQJUFRZZ.js.map → chunk-OYHAF2J2.js.map} +1 -1
- package/dist/{chunk-I2JNLAKW.js → chunk-RHKJPTON.js} +47 -15
- package/dist/chunk-RHKJPTON.js.map +1 -0
- package/dist/chunk-RT7P5AYU.js +6 -0
- package/dist/{chunk-K6MLOGU4.js.map → chunk-RT7P5AYU.js.map} +1 -1
- package/dist/{chunk-CBPDYYIH.js → chunk-UZP623Y4.js} +4 -4
- package/dist/{chunk-CBPDYYIH.js.map → chunk-UZP623Y4.js.map} +1 -1
- package/dist/{chunk-EW2ZMFUC.js → chunk-YJU7S7N6.js} +24 -6
- package/dist/chunk-YJU7S7N6.js.map +1 -0
- package/dist/{chunk-KAOSPAFK.js → chunk-Z3AYOZ3C.js} +7 -6
- package/dist/chunk-Z3AYOZ3C.js.map +1 -0
- package/dist/{chunk-RL6MHAOK.js → chunk-Z3MUWXP3.js} +4 -4
- package/dist/{chunk-RL6MHAOK.js.map → chunk-Z3MUWXP3.js.map} +1 -1
- package/dist/{chunk-KUZLILN3.js → chunk-Z7FM3ETS.js} +18 -4
- package/dist/chunk-Z7FM3ETS.js.map +1 -0
- package/dist/cli.js +96 -69
- package/dist/cli.js.map +1 -1
- package/dist/embed-worker-main.js +3 -3
- package/dist/{ensure-map-5E5TFPXJ.js → ensure-map-PHAJACFF.js} +13 -13
- package/dist/{ensure-map-5E5TFPXJ.js.map → ensure-map-PHAJACFF.js.map} +1 -1
- package/dist/graph-backend-4B3MTVIW.js +13 -0
- package/dist/{graph-backend-GQZXMNRI.js.map → graph-backend-4B3MTVIW.js.map} +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +12 -12
- package/dist/{interactive-7EZHEBHQ.js → interactive-WUXMXFNM.js} +24 -24
- package/dist/{interactive-7EZHEBHQ.js.map → interactive-WUXMXFNM.js.map} +1 -1
- package/dist/load-EUZSV73H.js +9 -0
- package/dist/{load-QBVKCWZT.js.map → load-EUZSV73H.js.map} +1 -1
- package/dist/{run-outcome-NQAU6DOA.js → run-outcome-O5PR7ZCK.js} +5 -5
- package/dist/{run-outcome-NQAU6DOA.js.map → run-outcome-O5PR7ZCK.js.map} +1 -1
- package/dist/runtime-session-PPQDTFIK.js +20 -0
- package/dist/{runtime-session-ZPGU4PGW.js.map → runtime-session-PPQDTFIK.js.map} +1 -1
- package/dist/session-WS7SOVJE.js +15 -0
- package/dist/{session-QNSYTLLJ.js.map → session-WS7SOVJE.js.map} +1 -1
- package/dist/session-store-KGONLWHN.js +4 -0
- package/dist/{session-store-F7NX7SZN.js.map → session-store-KGONLWHN.js.map} +1 -1
- package/dist/{stream-json-5WFD6HRO.js → stream-json-7MK3QQYG.js} +11 -11
- package/dist/{stream-json-5WFD6HRO.js.map → stream-json-7MK3QQYG.js.map} +1 -1
- package/dist/{vg-mcp-bridge-VTGXA6CO.js → vg-mcp-bridge-DQLCHBI6.js} +9 -9
- package/dist/{vg-mcp-bridge-VTGXA6CO.js.map → vg-mcp-bridge-DQLCHBI6.js.map} +1 -1
- package/dist/{vgd-54GEZWBI.js → vgd-Y25XSQGZ.js} +8 -8
- package/dist/vgd-Y25XSQGZ.js.map +1 -0
- package/package.json +6 -6
- package/dist/baseline-KVCXVZFQ.js +0 -9
- package/dist/chunk-7C5UKIXD.js.map +0 -1
- package/dist/chunk-EW2ZMFUC.js.map +0 -1
- package/dist/chunk-I2JNLAKW.js.map +0 -1
- package/dist/chunk-INIULQEP.js.map +0 -1
- package/dist/chunk-K6MLOGU4.js +0 -6
- package/dist/chunk-KAOSPAFK.js.map +0 -1
- package/dist/chunk-KUZLILN3.js.map +0 -1
- package/dist/chunk-SI4D7DYF.js.map +0 -1
- package/dist/chunk-Y4JO6LYP.js.map +0 -1
- package/dist/graph-backend-GQZXMNRI.js +0 -13
- package/dist/load-QBVKCWZT.js +0 -9
- package/dist/runtime-session-ZPGU4PGW.js +0 -20
- package/dist/session-QNSYTLLJ.js +0 -15
- package/dist/session-store-F7NX7SZN.js +0 -4
- package/dist/vgd-54GEZWBI.js.map +0 -1
package/dist/cli.js
CHANGED
|
@@ -1,37 +1,37 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { loadAdvancedScanHook, baselineCommand } from './chunk-
|
|
3
|
-
import { fetchCatalog, resolveProviders } from './chunk-
|
|
4
|
-
import { VGD_PROTOCOL_VERSION, startVgdServer } from './chunk-
|
|
2
|
+
import { loadAdvancedScanHook, baselineCommand } from './chunk-5ROZODMW.js';
|
|
3
|
+
import { fetchCatalog, resolveProviders } from './chunk-OYHAF2J2.js';
|
|
4
|
+
import { VGD_PROTOCOL_VERSION, startVgdServer } from './chunk-JYM4QT6F.js';
|
|
5
5
|
import './chunk-IS7VTH2Q.js';
|
|
6
|
-
import { telemetryOptOut, StatsSharer, statsEndpoint, isCI } from './chunk-
|
|
7
|
-
import { runCodeSession } from './chunk-
|
|
8
|
-
import { CONTEXT_POLICY_VERSION, computeFcsReport, renderFcsReportMarkdown, createTrajectoryCollector, runAgent } from './chunk-
|
|
6
|
+
import { telemetryOptOut, StatsSharer, statsEndpoint, isCI } from './chunk-KF2QT6RY.js';
|
|
7
|
+
import { runCodeSession } from './chunk-Z3AYOZ3C.js';
|
|
8
|
+
import { CONTEXT_POLICY_VERSION, computeFcsReport, renderFcsReportMarkdown, createTrajectoryCollector, runAgent } from './chunk-RHKJPTON.js';
|
|
9
9
|
import './chunk-543E6WDJ.js';
|
|
10
|
-
import { summarizeDiffs, ScriptedProvider } from './chunk-
|
|
10
|
+
import { summarizeDiffs, ScriptedProvider } from './chunk-ADP6ITGF.js';
|
|
11
11
|
import './chunk-7AVYKZEM.js';
|
|
12
12
|
import { buildModelInstallPlan } from './chunk-WHJMS7XC.js';
|
|
13
13
|
import { ensurePackage, ensureUnavailableMessage } from './chunk-REIGWTTH.js';
|
|
14
|
-
import { sha256Hex, generateKeypair, dssePae, DSSE_PAYLOAD_TYPE, keyId, registerBuild, readGlobal, applyGlobalOptions, ProgressBar, printLogo, runBuild } from './chunk-
|
|
15
|
-
export { runBuild } from './chunk-
|
|
14
|
+
import { sha256Hex, generateKeypair, dssePae, DSSE_PAYLOAD_TYPE, keyId, registerBuild, readGlobal, applyGlobalOptions, ProgressBar, printLogo, runBuild } from './chunk-5JJBGBP2.js';
|
|
15
|
+
export { runBuild } from './chunk-5JJBGBP2.js';
|
|
16
16
|
import { disableColor, info, c, json, out } from './chunk-CT5BS56U.js';
|
|
17
17
|
import { init_resolve_ollama, gatherSystemMemory, resolveOllamaBinary, hasOllamaBinary, resolve_ollama_exports } from './chunk-OWSFZQOP.js';
|
|
18
18
|
import { readOrchestratorState, writeOrchestratorState, parseMode, setDefaultMode, recommendMode, activePin, resolveMode, providerForBackend, QUALIFIED_PACKS, pinPack, unpinPack, buildOrchestratorStatus } from './chunk-NZELMYT4.js';
|
|
19
19
|
import { fmt, estimateModelBytes } from './chunk-7N4Y3E47.js';
|
|
20
20
|
import './chunk-IZDH67DX.js';
|
|
21
|
-
import './chunk-
|
|
21
|
+
import './chunk-GOPANQZT.js';
|
|
22
22
|
import { vgdSocketPath, vgdIsRunning, vgdRequest, vgdPidPath } from './chunk-RBIRXQR6.js';
|
|
23
23
|
import { defaultProcessEndpoint, startProcessHostServer, resolveInferenceIsolation } from './chunk-JFE7XCAE.js';
|
|
24
24
|
import { clearHostSessionPool, acquireHostSession, generateOnSession, listHostSessions, hostSessionPoolSize } from './chunk-3LOWJSAF.js';
|
|
25
25
|
import { buildIdentifierTrieFromGraph } from './chunk-5HYCB55P.js';
|
|
26
|
-
import { serveStdio, isRelevantChange, exportGraph, GraphSource, createServer, formatForExt, RefreshScheduler } from './chunk-
|
|
27
|
-
import { refreshIfStale } from './chunk-
|
|
28
|
-
import { recordCliCall, CLI_TOOL_ALIASES, savingsLedgerPath, clearSavings, readSavings, readUsage, readModelSavings, CAPSULE_RANKING_VERSION, SAVINGS_TOOLS, sanitizeClient } from './chunk-
|
|
29
|
-
import { CliError, ExitCode, driftCount, ASSISTANTS, detectAssistants, isAssistantInstalled, usageError, detectServeLaunch, installAssistant, writeNavigationConfig, uninstallAssistant, buildGraph, writeSnapshot, probeFreshness, discover, assistantById, SMALL_REPO_FILES, isSkippedDirName, SKIP_FILES, SKIP_DIRS } from './chunk-
|
|
30
|
-
import { resolveDsn, createWorkspaceDsn, writeStoredCredentials, credentialsPath, findGitRoot, ensureGitignored, gitignoreEntryForCredentials, clearStoredCredentials, parseDsn as parseDsn$1, uploadScanArtifact, dsnCommand, pushCommand, countTokens, shortestPath, pathDisconnect, testsToRun, detectRunner, coveringTests, FREE_PACK, readScanArtifact, publishPrivateLibrary, assessDocQuality, symbolsFromApi, fetchHostedDocsCached, selectForBudget, hostedBase, readStoredCredentials, projectCredentialsPath, homeCredentialsPath } from './chunk-
|
|
31
|
-
import { writeDefaultConfig, parseDsn, detectVcs, computeRepoFingerprint, resolveRepositoryName, fetchScanPreflight, runCoreScan, loadConfig, prepareCompressedUpload, computeDriftScore, titleBox, projectTypeToVulnEcosystem, driftBar, gitHistoryAvailable, buildVersionTimelines, findPackageAnyEcosystem, normalizeConstraint, findVersionCrossings, versionSatisfies, PROJECT_TYPE_TO_OSV_ECOSYSTEM, fetchRiskySymbols, perDependencyDrift } from './chunk-
|
|
26
|
+
import { serveStdio, isRelevantChange, exportGraph, GraphSource, createServer, formatForExt, RefreshScheduler } from './chunk-IJQOZ6ZD.js';
|
|
27
|
+
import { refreshIfStale } from './chunk-6GQLEDVK.js';
|
|
28
|
+
import { recordCliCall, CLI_TOOL_ALIASES, savingsLedgerPath, clearSavings, readSavings, readUsage, readModelSavings, CAPSULE_RANKING_VERSION, SAVINGS_TOOLS, sanitizeClient } from './chunk-CJNWHXQD.js';
|
|
29
|
+
import { CliError, ExitCode, driftCount, ASSISTANTS, detectAssistants, isAssistantInstalled, usageError, detectServeLaunch, installAssistant, writeNavigationConfig, uninstallAssistant, buildGraph, writeSnapshot, probeFreshness, discover, assistantById, SMALL_REPO_FILES, isSkippedDirName, SKIP_FILES, SKIP_DIRS } from './chunk-6423BHLN.js';
|
|
30
|
+
import { resolveDsn, createWorkspaceDsn, writeStoredCredentials, credentialsPath, findGitRoot, ensureGitignored, gitignoreEntryForCredentials, clearStoredCredentials, parseDsn as parseDsn$1, uploadScanArtifact, dsnCommand, pushCommand, countTokens, shortestPath, pathDisconnect, testsToRun, detectRunner, coveringTests, FREE_PACK, readScanArtifact, publishPrivateLibrary, assessDocQuality, symbolsFromApi, fetchHostedDocsCached, selectForBudget, hostedBase, readStoredCredentials, projectCredentialsPath, homeCredentialsPath } from './chunk-3WUTQYRY.js';
|
|
31
|
+
import { writeDefaultConfig, parseDsn, detectVcs, computeRepoFingerprint, resolveRepositoryName, fetchScanPreflight, runCoreScan, loadConfig, prepareCompressedUpload, computeDriftScore, titleBox, projectTypeToVulnEcosystem, driftBar, gitHistoryAvailable, buildVersionTimelines, findPackageAnyEcosystem, normalizeConstraint, findVersionCrossings, versionSatisfies, PROJECT_TYPE_TO_OSV_ECOSYSTEM, fetchRiskySymbols, perDependencyDrift } from './chunk-N6ZMZ5AI.js';
|
|
32
32
|
import { resolveIngestHost, dashHostForIngestHost, availableRegionIds, ingestHostForRegionId } from './chunk-HTLDXEHW.js';
|
|
33
33
|
import './chunk-VIWZ4QT7.js';
|
|
34
|
-
import { inventory, enrichOnline, ECOSYSTEMS, catalogPath, libDir, loadCatalog, driftFor, addLibrary, resolveLib, libId, resolveVersion, readDoc, localPackageDocs, localApiSurface } from './chunk-
|
|
34
|
+
import { inventory, enrichOnline, ECOSYSTEMS, catalogPath, libDir, loadCatalog, driftFor, addLibrary, resolveLib, libId, resolveVersion, readDoc, localPackageDocs, localApiSurface } from './chunk-UZP623Y4.js';
|
|
35
35
|
import { discoverModels } from './chunk-CQDUBAQY.js';
|
|
36
36
|
import { freeBytesOnVolume, weightStoreDir, listCachedWeights, ensureWeightCached, catalogIntegrityReport } from './chunk-OV4KGXPD.js';
|
|
37
37
|
import './chunk-5I4VSBWQ.js';
|
|
@@ -39,13 +39,13 @@ import { pathExists as pathExists$1, parseExcludePatterns } from './chunk-DT4KIV
|
|
|
39
39
|
import { ensureDir, pathExists, readJsonFile, writeTextFile, writeJsonFile } from './chunk-CRAMOEBE.js';
|
|
40
40
|
import { init_cli_invocation, resolveCliInvocation, NPX_INVOCATION } from './chunk-3LSG7Z4I.js';
|
|
41
41
|
import { resolveOne } from './chunk-J7LKEB2R.js';
|
|
42
|
-
import { queryGraphSemantic, queryGraph, indexFor, impactOf } from './chunk-
|
|
42
|
+
import { queryGraphSemantic, queryGraph, indexFor, impactOf } from './chunk-YJU7S7N6.js';
|
|
43
43
|
import { resolvedGrammarFiles, grammarSetVersion } from './chunk-UTNNGKKX.js';
|
|
44
44
|
import './chunk-RXP66R2E.js';
|
|
45
|
-
import { embeddingsCached, resolveEmbedModel, loadEmbedder, getNodeEmbeddings, unavailableMessage, countPending, modelCacheInfo, embeddingsPath, clearModelCache, withTimeout } from './chunk-
|
|
46
|
-
import { loadGraph, loadGraphPreferIndex, SCHEMA_VERSION } from './chunk-
|
|
47
|
-
import { cacheDir, resolveGraphPath, analyzeQuestion, loadTopicTags, renderReport, resetRelevanceProviderCache, loadRelevanceProvider, loadGraphFileWithSnapshot, serializeGraph, stableStringify, writeArtifacts, vibgrateDir, mapFileExists, relevanceModuleDir, parseGraph, ensureVibgrateGitignore } from './chunk-
|
|
48
|
-
import { VERSION } from './chunk-
|
|
45
|
+
import { embeddingsCached, resolveEmbedModel, loadEmbedder, getNodeEmbeddings, unavailableMessage, countPending, modelCacheInfo, embeddingsPath, clearModelCache, withTimeout } from './chunk-KBP7GJV6.js';
|
|
46
|
+
import { loadGraph, loadGraphPreferIndex, SCHEMA_VERSION } from './chunk-7ZHSSGUF.js';
|
|
47
|
+
import { cacheDir, resolveGraphPath, analyzeQuestion, loadTopicTags, renderReport, resetRelevanceProviderCache, loadRelevanceProvider, loadGraphFileWithSnapshot, serializeGraph, stableStringify, writeArtifacts, vibgrateDir, mapFileExists, relevanceModuleDir, parseGraph, ensureVibgrateGitignore } from './chunk-EWZKOU66.js';
|
|
48
|
+
import { VERSION } from './chunk-RT7P5AYU.js';
|
|
49
49
|
import './chunk-BWPBB45M.js';
|
|
50
50
|
import { canonicalize, hashString, hashBytes } from './chunk-JFGYT6BI.js';
|
|
51
51
|
import './chunk-BPF3YX2U.js';
|
|
@@ -3092,10 +3092,10 @@ function pruneArtifactProjects(a) {
|
|
|
3092
3092
|
return { ...a, projects, findings };
|
|
3093
3093
|
}
|
|
3094
3094
|
function projectByPath(a, projectPath) {
|
|
3095
|
-
const
|
|
3095
|
+
const norm = (p) => path41.normalize((p === "" ? "." : p).replace(/\\/g, "/"));
|
|
3096
|
+
const want = norm(projectPath);
|
|
3096
3097
|
for (const proj of a.projects ?? []) {
|
|
3097
|
-
|
|
3098
|
-
if (got === want) return proj;
|
|
3098
|
+
if (norm(proj.path) === want) return proj;
|
|
3099
3099
|
}
|
|
3100
3100
|
return void 0;
|
|
3101
3101
|
}
|
|
@@ -3103,7 +3103,7 @@ function buildProjectRefs(rootDir, projects) {
|
|
|
3103
3103
|
if (projects.length === 0) return void 0;
|
|
3104
3104
|
const byPath = /* @__PURE__ */ new Map();
|
|
3105
3105
|
for (const p of projects) {
|
|
3106
|
-
const rel = p.path === "" ? "." : p.path;
|
|
3106
|
+
const rel = (p.path === "" ? "." : p.path).replace(/\\/g, "/");
|
|
3107
3107
|
const prev = byPath.get(rel);
|
|
3108
3108
|
if (!prev) {
|
|
3109
3109
|
byPath.set(rel, p);
|
|
@@ -6986,7 +6986,7 @@ function registerCode(program) {
|
|
|
6986
6986
|
try {
|
|
6987
6987
|
const { parseMode: parseMode2, resolveMode: resolveMode2, readOrchestratorState: readOrchestratorState2, activePin: activePin2 } = await import('./model-orchestrator-LHYPJBFH.js');
|
|
6988
6988
|
const { gatherSystemMemory: gatherSystemMemory2 } = await import('./local-runtime-2ED33KK6.js');
|
|
6989
|
-
const { loadGraph: loadGraph2 } = await import('./load-
|
|
6989
|
+
const { loadGraph: loadGraph2 } = await import('./load-EUZSV73H.js');
|
|
6990
6990
|
const state = readOrchestratorState2();
|
|
6991
6991
|
const mode = parseMode2(modeFlag) ?? state.defaultMode ?? void 0;
|
|
6992
6992
|
const pin = mode ? activePin2(mode, state) : null;
|
|
@@ -7071,7 +7071,7 @@ function registerCode(program) {
|
|
|
7071
7071
|
if (!(process.stdin.isTTY && process.stdout.isTTY)) {
|
|
7072
7072
|
throw usageError('say what to change, e.g. `vg code "add a --timeout flag to the scan command"` (guided mode needs an interactive terminal)');
|
|
7073
7073
|
}
|
|
7074
|
-
const { runInteractive } = await import('./interactive-
|
|
7074
|
+
const { runInteractive } = await import('./interactive-WUXMXFNM.js');
|
|
7075
7075
|
await runInteractive(
|
|
7076
7076
|
rootOf(global),
|
|
7077
7077
|
global,
|
|
@@ -7101,7 +7101,7 @@ function registerCode(program) {
|
|
|
7101
7101
|
}
|
|
7102
7102
|
if (!instruction && !stdinFirstTurn) throw usageError('say what to change, e.g. `vg code "add a --timeout flag to the scan command"`');
|
|
7103
7103
|
{
|
|
7104
|
-
const { ensureCodeMap } = await import('./ensure-map-
|
|
7104
|
+
const { ensureCodeMap } = await import('./ensure-map-PHAJACFF.js');
|
|
7105
7105
|
const mapRoot = rootOf(global);
|
|
7106
7106
|
try {
|
|
7107
7107
|
await ensureCodeMap(mapRoot, global, {
|
|
@@ -7186,20 +7186,20 @@ function registerCode(program) {
|
|
|
7186
7186
|
process.stdout.write(JSON.stringify(line) + "\n");
|
|
7187
7187
|
};
|
|
7188
7188
|
try {
|
|
7189
|
-
const { RunOutcomeRecorder, newOneShotRunId, turnRunId } = await import('./run-outcome-
|
|
7189
|
+
const { RunOutcomeRecorder, newOneShotRunId, turnRunId } = await import('./run-outcome-O5PR7ZCK.js');
|
|
7190
7190
|
const primarySlug = route.providers[0]?.model.includes("/") ? route.providers[0].model.split("/")[0] : route.providers[0]?.id;
|
|
7191
|
-
const { runCodeStreamJson, parseHostMessage } = await import('./stream-json-
|
|
7192
|
-
const { nodeCodeFs } = await import('./session-
|
|
7191
|
+
const { runCodeStreamJson, parseHostMessage } = await import('./stream-json-7MK3QQYG.js');
|
|
7192
|
+
const { nodeCodeFs } = await import('./session-WS7SOVJE.js');
|
|
7193
7193
|
const readline6 = await import('readline');
|
|
7194
7194
|
const child = await import('child_process');
|
|
7195
7195
|
const { loadOrDiscoverFederation } = await import('./federation-MDQPO3PW.js');
|
|
7196
7196
|
const { resolveExecutionEnv } = await import('./execution-env-4MS5AYAN.js');
|
|
7197
7197
|
const { resolveModelExecutionProfile, mergeModelExecutionProfile } = await import('./model-execution-profile-ELWF3Z6H.js');
|
|
7198
|
-
const { startCodeRuntimeSession } = await import('./runtime-session-
|
|
7199
|
-
const { resolveGraphBackend } = await import('./graph-backend-
|
|
7198
|
+
const { startCodeRuntimeSession } = await import('./runtime-session-PPQDTFIK.js');
|
|
7199
|
+
const { resolveGraphBackend } = await import('./graph-backend-4B3MTVIW.js');
|
|
7200
7200
|
const { detectGitRef } = await import('./git-ref-RSRAN4OH.js');
|
|
7201
7201
|
const { repositoryIdFromRoot } = await import('./paths-62AKTFSR.js');
|
|
7202
|
-
const { vgdRequest: vgdRequest2 } = await import('./vgd-
|
|
7202
|
+
const { vgdRequest: vgdRequest2 } = await import('./vgd-Y25XSQGZ.js');
|
|
7203
7203
|
const federation = loadOrDiscoverFederation(root2);
|
|
7204
7204
|
const modelProfile = mergeModelExecutionProfile(
|
|
7205
7205
|
resolveModelExecutionProfile({
|
|
@@ -7257,7 +7257,7 @@ ${res.stderr}` : ""),
|
|
|
7257
7257
|
exitCode: res.status ?? 1
|
|
7258
7258
|
};
|
|
7259
7259
|
};
|
|
7260
|
-
const { createVgBuiltinMcpTools, mergeExternalToolsets } = await import('./vg-mcp-bridge-
|
|
7260
|
+
const { createVgBuiltinMcpTools, mergeExternalToolsets } = await import('./vg-mcp-bridge-DQLCHBI6.js');
|
|
7261
7261
|
const vgBuiltin = createVgBuiltinMcpTools({
|
|
7262
7262
|
getGraph: () => graph,
|
|
7263
7263
|
root: root2,
|
|
@@ -7351,8 +7351,8 @@ ${res.stderr}` : ""),
|
|
|
7351
7351
|
};
|
|
7352
7352
|
try {
|
|
7353
7353
|
if (opts.session) {
|
|
7354
|
-
const { runCodeStreamJsonSession } = await import('./stream-json-
|
|
7355
|
-
const { runAgent: runAgent2 } = await import('./agent-
|
|
7354
|
+
const { runCodeStreamJsonSession } = await import('./stream-json-7MK3QQYG.js');
|
|
7355
|
+
const { runAgent: runAgent2 } = await import('./agent-N3CP3SPI.js');
|
|
7356
7356
|
const {
|
|
7357
7357
|
condenseSession,
|
|
7358
7358
|
loadLatestSession,
|
|
@@ -7360,7 +7360,7 @@ ${res.stderr}` : ""),
|
|
|
7360
7360
|
recordTask,
|
|
7361
7361
|
saveSession,
|
|
7362
7362
|
summarizeSession
|
|
7363
|
-
} = await import('./session-store-
|
|
7363
|
+
} = await import('./session-store-KGONLWHN.js');
|
|
7364
7364
|
const resumedRecord = opts.continue ? loadLatestSession(root2) : void 0;
|
|
7365
7365
|
let record = resumedRecord ?? newSession(
|
|
7366
7366
|
`s${Date.now().toString(36)}`,
|
|
@@ -7520,13 +7520,13 @@ ${res.stderr}` : ""),
|
|
|
7520
7520
|
if (!autonomous && !tty) {
|
|
7521
7521
|
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).");
|
|
7522
7522
|
}
|
|
7523
|
-
const { agentTask } = await import('./interactive-
|
|
7524
|
-
const { nodeCodeFs } = await import('./session-
|
|
7523
|
+
const { agentTask } = await import('./interactive-WUXMXFNM.js');
|
|
7524
|
+
const { nodeCodeFs } = await import('./session-WS7SOVJE.js');
|
|
7525
7525
|
const { TtyPrompter } = await import('./ui-K7D3BCHD.js');
|
|
7526
7526
|
let priorSummary;
|
|
7527
7527
|
let priorInstruction;
|
|
7528
7528
|
if (opts.continue) {
|
|
7529
|
-
const { loadLatestSession, summarizeSession } = await import('./session-store-
|
|
7529
|
+
const { loadLatestSession, summarizeSession } = await import('./session-store-KGONLWHN.js');
|
|
7530
7530
|
const prev = loadLatestSession(root2);
|
|
7531
7531
|
if (prev) {
|
|
7532
7532
|
priorSummary = summarizeSession(prev);
|
|
@@ -7534,7 +7534,7 @@ ${res.stderr}` : ""),
|
|
|
7534
7534
|
}
|
|
7535
7535
|
}
|
|
7536
7536
|
const prompter = tty ? new TtyPrompter() : void 0;
|
|
7537
|
-
const { createVgBuiltinMcpTools, mergeExternalToolsets } = await import('./vg-mcp-bridge-
|
|
7537
|
+
const { createVgBuiltinMcpTools, mergeExternalToolsets } = await import('./vg-mcp-bridge-DQLCHBI6.js');
|
|
7538
7538
|
const vgBuiltin = createVgBuiltinMcpTools({
|
|
7539
7539
|
getGraph: () => graph,
|
|
7540
7540
|
root: root2,
|
|
@@ -7558,11 +7558,11 @@ ${res.stderr}` : ""),
|
|
|
7558
7558
|
const { loadFederation } = await import('./federation-MDQPO3PW.js');
|
|
7559
7559
|
const { resolveExecutionEnv } = await import('./execution-env-4MS5AYAN.js');
|
|
7560
7560
|
const { resolveModelExecutionProfile, mergeModelExecutionProfile } = await import('./model-execution-profile-ELWF3Z6H.js');
|
|
7561
|
-
const { startCodeRuntimeSession } = await import('./runtime-session-
|
|
7562
|
-
const { resolveGraphBackend } = await import('./graph-backend-
|
|
7561
|
+
const { startCodeRuntimeSession } = await import('./runtime-session-PPQDTFIK.js');
|
|
7562
|
+
const { resolveGraphBackend } = await import('./graph-backend-4B3MTVIW.js');
|
|
7563
7563
|
const { detectGitRef } = await import('./git-ref-RSRAN4OH.js');
|
|
7564
7564
|
const { repositoryIdFromRoot } = await import('./paths-62AKTFSR.js');
|
|
7565
|
-
const { vgdRequest: vgdRequest2 } = await import('./vgd-
|
|
7565
|
+
const { vgdRequest: vgdRequest2 } = await import('./vgd-Y25XSQGZ.js');
|
|
7566
7566
|
const federation = loadFederation(root2);
|
|
7567
7567
|
const modelProfile = mergeModelExecutionProfile(
|
|
7568
7568
|
resolveModelExecutionProfile({
|
|
@@ -8333,10 +8333,16 @@ function registerDaemon(program) {
|
|
|
8333
8333
|
}
|
|
8334
8334
|
const child = await startDetachedVgd(socketPath);
|
|
8335
8335
|
const res = await vgdRequest({ op: "status" }, { socketPath });
|
|
8336
|
+
if (!res.ok) {
|
|
8337
|
+
throw new CliError(
|
|
8338
|
+
`vgd started (pid ${child ?? "?"}) but status failed: ${res.error} (${socketPath})`,
|
|
8339
|
+
ExitCode.ERROR
|
|
8340
|
+
);
|
|
8341
|
+
}
|
|
8336
8342
|
if (global.json) {
|
|
8337
|
-
json({ running: true, ensured: true, ...res
|
|
8343
|
+
json({ running: true, ensured: true, ...res });
|
|
8338
8344
|
} else if (!global.quiet) {
|
|
8339
|
-
const pid =
|
|
8345
|
+
const pid = "pid" in res ? res.pid : child;
|
|
8340
8346
|
info(`vgd \xB7 started in background pid ${pid} \xB7 ${c.dim(socketPath)}`);
|
|
8341
8347
|
}
|
|
8342
8348
|
});
|
|
@@ -8472,7 +8478,7 @@ function registerDaemon(program) {
|
|
|
8472
8478
|
throw new CliError(loaded.error, ExitCode.NOT_FOUND);
|
|
8473
8479
|
}
|
|
8474
8480
|
if (!loaded.ok) {
|
|
8475
|
-
const { loadGraph: loadGraph2 } = await import('./load-
|
|
8481
|
+
const { loadGraph: loadGraph2 } = await import('./load-EUZSV73H.js');
|
|
8476
8482
|
const { detectGitRef } = await import('./git-ref-RSRAN4OH.js');
|
|
8477
8483
|
const { repositoryIdFromRoot } = await import('./paths-62AKTFSR.js');
|
|
8478
8484
|
const graph = loadGraph2(root2, global.graph);
|
|
@@ -8594,19 +8600,17 @@ function socketOf(cmd) {
|
|
|
8594
8600
|
return vgdSocketPath();
|
|
8595
8601
|
}
|
|
8596
8602
|
function spawnDetachedDaemonStart(socketPath) {
|
|
8603
|
+
const opts = {
|
|
8604
|
+
detached: true,
|
|
8605
|
+
stdio: "ignore",
|
|
8606
|
+
env: process.env,
|
|
8607
|
+
windowsHide: true
|
|
8608
|
+
};
|
|
8597
8609
|
const entry = process.argv[1];
|
|
8598
8610
|
if (entry && (entry.endsWith(".js") || entry.endsWith(".mjs") || entry.endsWith(".cjs"))) {
|
|
8599
|
-
return spawn(process.execPath, [entry, "daemon", "start", "--socket", socketPath],
|
|
8600
|
-
detached: true,
|
|
8601
|
-
stdio: "ignore",
|
|
8602
|
-
env: process.env
|
|
8603
|
-
});
|
|
8611
|
+
return spawn(process.execPath, [entry, "daemon", "start", "--socket", socketPath], opts);
|
|
8604
8612
|
}
|
|
8605
|
-
return spawn(process.argv[0] || "vg", ["daemon", "start", "--socket", socketPath],
|
|
8606
|
-
detached: true,
|
|
8607
|
-
stdio: "ignore",
|
|
8608
|
-
env: process.env
|
|
8609
|
-
});
|
|
8613
|
+
return spawn(process.argv[0] || "vg", ["daemon", "start", "--socket", socketPath], opts);
|
|
8610
8614
|
}
|
|
8611
8615
|
function sleep(ms) {
|
|
8612
8616
|
return new Promise((r) => setTimeout(r, ms));
|
|
@@ -8614,12 +8618,22 @@ function sleep(ms) {
|
|
|
8614
8618
|
async function startDetachedVgd(socketPath) {
|
|
8615
8619
|
const child = spawnDetachedDaemonStart(socketPath);
|
|
8616
8620
|
child.unref();
|
|
8617
|
-
const
|
|
8621
|
+
const readyMs = 3e4;
|
|
8622
|
+
const deadline = Date.now() + readyMs;
|
|
8618
8623
|
while (Date.now() < deadline) {
|
|
8619
|
-
await sleep(
|
|
8624
|
+
await sleep(150);
|
|
8620
8625
|
if (await vgdIsRunning({ socketPath })) return child.pid;
|
|
8626
|
+
if (child.exitCode != null && child.exitCode !== 0) {
|
|
8627
|
+
throw new CliError(
|
|
8628
|
+
`vgd child exited ${child.exitCode} before becoming ready at ${socketPath}`,
|
|
8629
|
+
ExitCode.ERROR
|
|
8630
|
+
);
|
|
8631
|
+
}
|
|
8621
8632
|
}
|
|
8622
|
-
throw new CliError(
|
|
8633
|
+
throw new CliError(
|
|
8634
|
+
`vgd failed to become ready within ${Math.round(readyMs / 1e3)}s at ${socketPath}`,
|
|
8635
|
+
ExitCode.ERROR
|
|
8636
|
+
);
|
|
8623
8637
|
}
|
|
8624
8638
|
async function stopVgd(socketPath) {
|
|
8625
8639
|
if (!await vgdIsRunning({ socketPath })) return "not-running";
|
|
@@ -8877,7 +8891,7 @@ var initCommand = new Command("init").description("Initialize vibgrate in a proj
|
|
|
8877
8891
|
console.log(chalk7.green("\u2714") + ` Created ${chalk7.bold("vibgrate.config.ts")}`);
|
|
8878
8892
|
}
|
|
8879
8893
|
if (opts.baseline) {
|
|
8880
|
-
const { runBaseline } = await import('./baseline-
|
|
8894
|
+
const { runBaseline } = await import('./baseline-ZMRZRGFI.js');
|
|
8881
8895
|
await runBaseline(rootDir);
|
|
8882
8896
|
}
|
|
8883
8897
|
console.log("");
|
|
@@ -9433,7 +9447,12 @@ var scanCommand = new Command("scan").description("Scan a project for upgrade dr
|
|
|
9433
9447
|
try {
|
|
9434
9448
|
const preflight = await fetchScanPreflight(parsed, ingestHost, {
|
|
9435
9449
|
repositoryName,
|
|
9436
|
-
vcsSha: fingerprint.vcsSha
|
|
9450
|
+
vcsSha: fingerprint.vcsSha,
|
|
9451
|
+
// Canonical repo identity (credential-redacted by detectVcs) — the
|
|
9452
|
+
// server matches on this first, so re-scanning an already-mapped
|
|
9453
|
+
// repository under a different display name (e.g. a fresh clone in
|
|
9454
|
+
// a temp dir) is not miscounted as a NEW repo against the plan cap.
|
|
9455
|
+
remoteUrl: vcs.remoteUrl
|
|
9437
9456
|
});
|
|
9438
9457
|
pinnedRegion = preflight.region;
|
|
9439
9458
|
planTier = preflight.plan?.tier;
|
|
@@ -10429,7 +10448,7 @@ ${String(err)}` }));
|
|
|
10429
10448
|
async function releaseWindowsFileLocks(cwd, keepVersion) {
|
|
10430
10449
|
reapAndReport(cwd, keepVersion);
|
|
10431
10450
|
try {
|
|
10432
|
-
const { vgdSocketPath: vgdSocketPath2 } = await import('./vgd-
|
|
10451
|
+
const { vgdSocketPath: vgdSocketPath2 } = await import('./vgd-Y25XSQGZ.js');
|
|
10433
10452
|
const result = await stopVgd(vgdSocketPath2());
|
|
10434
10453
|
if (result === "stopped") {
|
|
10435
10454
|
console.log(chalk7.dim("Stopped the vgd daemon so its files can be replaced \u2014 it restarts on the next command."));
|
|
@@ -10554,7 +10573,7 @@ var updateCommand = new Command("update").description("Update vibgrate to the la
|
|
|
10554
10573
|
);
|
|
10555
10574
|
async function rewarmVgdAndReport(cwd) {
|
|
10556
10575
|
try {
|
|
10557
|
-
const { vgdIsRunning: vgdIsRunning2, vgdRequest: vgdRequest2 } = await import('./vgd-
|
|
10576
|
+
const { vgdIsRunning: vgdIsRunning2, vgdRequest: vgdRequest2 } = await import('./vgd-Y25XSQGZ.js');
|
|
10558
10577
|
if (!await vgdIsRunning2()) return;
|
|
10559
10578
|
const loaded = await vgdRequest2({ op: "load-graph", root: cwd });
|
|
10560
10579
|
if (!loaded.ok || !("repositoryId" in loaded)) return;
|
|
@@ -10675,7 +10694,7 @@ async function repositoryIdentity(rootDir, override) {
|
|
|
10675
10694
|
return { name: override?.trim() || void 0 };
|
|
10676
10695
|
}
|
|
10677
10696
|
}
|
|
10678
|
-
var fixCommand = new Command("fix").description("Get ranked, risk-tiered upgrade plans from the hosted planner and optionally apply them (prompts before changing files; --yes applies non-interactively, --dry-run previews, --no-apply only prints). Requires login/DSN.").argument("[path]", "Path to analyse", ".").option("--in <file>", "Scan artifact to read", ".vibgrate/scan_result.json").option("--format <format>", "Output format (text|json|md)", "text").option("--dsn <dsn>", 'DSN token (or use VIBGRATE_DSN env / "vg login")').option("--region <region>", "Override data residency region (us, eu)").option("--repository-name <name>", "Override the repository name recorded for this plan").option("--plan <tier>", "Apply a specific plan non-interactively (safe|balanced|aggressive)").option("--yes", "Apply the recommended plan without prompting").option("--dry-run", "
|
|
10697
|
+
var fixCommand = new Command("fix").description("Get ranked, risk-tiered upgrade plans from the hosted planner and optionally apply them (prompts before changing files; --yes applies non-interactively, --dry-run previews, --no-apply only prints). Requires login/DSN.").argument("[path]", "Path to analyse", ".").option("--in <file>", "Scan artifact to read", ".vibgrate/scan_result.json").option("--format <format>", "Output format (text|json|md)", "text").option("--dsn <dsn>", 'DSN token (or use VIBGRATE_DSN env / "vg login")').option("--region <region>", "Override data residency region (us, eu)").option("--repository-name <name>", "Override the repository name recorded for this plan").option("--plan <tier>", "Apply a specific plan non-interactively (safe|balanced|aggressive)").option("--yes", "Apply the recommended plan without prompting").option("--dry-run", "Preview the recommended plan (or --plan <tier>) without applying; never prompts").option("--no-apply", "Only print the plans; never modify the project").option("--fail-on-vulns <severity>", "Exit non-zero if the recommended plan leaves an advisory at/above this severity unresolved (low|moderate|high|critical)").action(async (targetPath, opts) => {
|
|
10679
10698
|
const rootDir = path41.resolve(targetPath);
|
|
10680
10699
|
if (!await pathExists(rootDir)) {
|
|
10681
10700
|
console.error(chalk7.red(`Path does not exist: ${rootDir}`));
|
|
@@ -10905,8 +10924,16 @@ async function runApplyFlow(rootDir, artifact, response, opts, canonicalTier) {
|
|
|
10905
10924
|
}
|
|
10906
10925
|
} else if (nonEmpty.length === 1) {
|
|
10907
10926
|
chosen = nonEmpty[0];
|
|
10908
|
-
} else if (opts.yes) {
|
|
10927
|
+
} else if (opts.yes || opts.dryRun) {
|
|
10909
10928
|
chosen = response.plans.find((p) => p.tier === response.recommended) ?? nonEmpty[0];
|
|
10929
|
+
if (opts.dryRun && !opts.yes && nonEmpty.length > 1) {
|
|
10930
|
+
console.log(
|
|
10931
|
+
chalk7.dim(
|
|
10932
|
+
`
|
|
10933
|
+
Dry-run previews the recommended (${chosen.tier}) plan \u2014 nothing will be written. Pass --plan <safe|balanced|aggressive> to preview another tier.`
|
|
10934
|
+
)
|
|
10935
|
+
);
|
|
10936
|
+
}
|
|
10910
10937
|
} else if (process.stdin.isTTY && process.stdout.isTTY) {
|
|
10911
10938
|
const tier = await promptPlanSelection(response);
|
|
10912
10939
|
if (!tier) {
|
|
@@ -10915,7 +10942,7 @@ async function runApplyFlow(rootDir, artifact, response, opts, canonicalTier) {
|
|
|
10915
10942
|
}
|
|
10916
10943
|
chosen = response.plans.find((p) => p.tier === tier);
|
|
10917
10944
|
} else {
|
|
10918
|
-
console.log(chalk7.dim("\nMultiple plans available \u2014 re-run with --plan <tier> or --yes to apply, or --dry-run to preview."));
|
|
10945
|
+
console.log(chalk7.dim("\nMultiple plans available \u2014 re-run with --plan <tier> or --yes to apply, or --dry-run to preview the recommended plan."));
|
|
10919
10946
|
return;
|
|
10920
10947
|
}
|
|
10921
10948
|
if (!chosen || chosen.upgrades.length === 0) {
|