@ankurhalder/codebase-snapshot 4.0.2 → 4.0.3
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/bin.js +8 -5
- package/dist/{chunk-CY3XU5TS.js → chunk-L7QBLC4C.js} +10 -7
- package/dist/cli.cjs +8 -5
- package/dist/cli.js +1 -1
- package/dist/index.cjs +8 -5
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/bin.js
CHANGED
|
@@ -5228,6 +5228,9 @@ function validateSnapshot(configInput) {
|
|
|
5228
5228
|
});
|
|
5229
5229
|
}
|
|
5230
5230
|
}
|
|
5231
|
+
const maskValue = (value) => findSecretInPath(value, config.secretRules)?.masked ?? value;
|
|
5232
|
+
const currentExcludes = config.excludePatterns.map(maskValue);
|
|
5233
|
+
const currentInclude = config.include.map(maskValue);
|
|
5231
5234
|
const recorded = manifest.config;
|
|
5232
5235
|
if (recorded && typeof recorded === "object") {
|
|
5233
5236
|
if (recorded.maxPartBytes !== config.maxPartBytes) {
|
|
@@ -5256,15 +5259,15 @@ function validateSnapshot(configInput) {
|
|
|
5256
5259
|
);
|
|
5257
5260
|
}
|
|
5258
5261
|
const recordedExcludes = Array.isArray(recorded.excludePatterns) ? recorded.excludePatterns : [];
|
|
5259
|
-
if (recordedExcludes.join("\0") !==
|
|
5262
|
+
if (recordedExcludes.join("\0") !== currentExcludes.join("\0")) {
|
|
5260
5263
|
drift.configMismatches.push(
|
|
5261
|
-
`excludePatterns: manifest [${recordedExcludes.join(", ")}] vs current [${
|
|
5264
|
+
`excludePatterns: manifest [${recordedExcludes.join(", ")}] vs current [${currentExcludes.join(", ")}]`
|
|
5262
5265
|
);
|
|
5263
5266
|
}
|
|
5264
5267
|
const recordedInclude = Array.isArray(recorded.include) ? recorded.include : [];
|
|
5265
|
-
if (recordedInclude.join("\0") !==
|
|
5268
|
+
if (recordedInclude.join("\0") !== currentInclude.join("\0")) {
|
|
5266
5269
|
drift.configMismatches.push(
|
|
5267
|
-
`include: manifest [${recordedInclude.join(", ")}] vs current [${
|
|
5270
|
+
`include: manifest [${recordedInclude.join(", ")}] vs current [${currentInclude.join(", ")}]`
|
|
5268
5271
|
);
|
|
5269
5272
|
}
|
|
5270
5273
|
if (recorded?.artifacts && typeof recorded.artifacts === "object") {
|
|
@@ -5444,7 +5447,7 @@ function validateSnapshot(configInput) {
|
|
|
5444
5447
|
|
|
5445
5448
|
// src/index.ts
|
|
5446
5449
|
var GENERATOR_NAME = "@ankurhalder/codebase-snapshot";
|
|
5447
|
-
var GENERATOR_VERSION = "4.0.
|
|
5450
|
+
var GENERATOR_VERSION = "4.0.3";
|
|
5448
5451
|
var SCHEMA_VERSION = "3.0.0";
|
|
5449
5452
|
function sha256Hex2(input) {
|
|
5450
5453
|
return crypto3.createHash("sha256").update(input).digest("hex");
|
|
@@ -4276,6 +4276,9 @@ function validateSnapshot(configInput) {
|
|
|
4276
4276
|
});
|
|
4277
4277
|
}
|
|
4278
4278
|
}
|
|
4279
|
+
const maskValue = (value) => findSecretInPath(value, config.secretRules)?.masked ?? value;
|
|
4280
|
+
const currentExcludes = config.excludePatterns.map(maskValue);
|
|
4281
|
+
const currentInclude = config.include.map(maskValue);
|
|
4279
4282
|
const recorded = manifest.config;
|
|
4280
4283
|
if (recorded && typeof recorded === "object") {
|
|
4281
4284
|
if (recorded.maxPartBytes !== config.maxPartBytes) {
|
|
@@ -4304,15 +4307,15 @@ function validateSnapshot(configInput) {
|
|
|
4304
4307
|
);
|
|
4305
4308
|
}
|
|
4306
4309
|
const recordedExcludes = Array.isArray(recorded.excludePatterns) ? recorded.excludePatterns : [];
|
|
4307
|
-
if (recordedExcludes.join("\0") !==
|
|
4310
|
+
if (recordedExcludes.join("\0") !== currentExcludes.join("\0")) {
|
|
4308
4311
|
drift.configMismatches.push(
|
|
4309
|
-
`excludePatterns: manifest [${recordedExcludes.join(", ")}] vs current [${
|
|
4312
|
+
`excludePatterns: manifest [${recordedExcludes.join(", ")}] vs current [${currentExcludes.join(", ")}]`
|
|
4310
4313
|
);
|
|
4311
4314
|
}
|
|
4312
4315
|
const recordedInclude = Array.isArray(recorded.include) ? recorded.include : [];
|
|
4313
|
-
if (recordedInclude.join("\0") !==
|
|
4316
|
+
if (recordedInclude.join("\0") !== currentInclude.join("\0")) {
|
|
4314
4317
|
drift.configMismatches.push(
|
|
4315
|
-
`include: manifest [${recordedInclude.join(", ")}] vs current [${
|
|
4318
|
+
`include: manifest [${recordedInclude.join(", ")}] vs current [${currentInclude.join(", ")}]`
|
|
4316
4319
|
);
|
|
4317
4320
|
}
|
|
4318
4321
|
if (recorded?.artifacts && typeof recorded.artifacts === "object") {
|
|
@@ -5407,7 +5410,7 @@ async function runInit(options) {
|
|
|
5407
5410
|
|
|
5408
5411
|
// src/index.ts
|
|
5409
5412
|
var GENERATOR_NAME = "@ankurhalder/codebase-snapshot";
|
|
5410
|
-
var GENERATOR_VERSION = "4.0.
|
|
5413
|
+
var GENERATOR_VERSION = "4.0.3";
|
|
5411
5414
|
var SCHEMA_VERSION = "3.0.0";
|
|
5412
5415
|
function sha256Hex2(input) {
|
|
5413
5416
|
return crypto.createHash("sha256").update(input).digest("hex");
|
|
@@ -6455,5 +6458,5 @@ async function generateSnapshotAsync(configInput, options) {
|
|
|
6455
6458
|
}
|
|
6456
6459
|
|
|
6457
6460
|
export { ARTIFACT_NAMES, DEFAULT_ANSWERS, DEFAULT_SECRET_PATTERNS, GENERATOR_NAME, GENERATOR_VERSION, LANGUAGE_PROFILES, MIN_MAX_PART_BYTES, PRESETS, PromptCancelled, SCHEMA_VERSION, anchorForPath, assertReplaceable, assertUsableConfigInput, collectFiles, compareManifests, countLines, defineConfig, detectLanguage, detectPreset, explainPath, fenceForContent, fenceForText, generateProjectTree, generateSnapshot, generateSnapshotAsync, getPreset, globToRegExp, isBinaryBuffer, isBinaryExtension, isBinaryFile, isInteractive, isResolvedConfig, isSensitivePath, listPresetNames, loadConfigFile, loadConfigFileDetailed, loadManifest, markResolvedConfig, matchRule, matchesExclude, normalizeResolvedConfig, parseByteSize, partitionFiles, profileForPath, renderConfig, renderDiffText, renderExplainText, renderMinimalConfig, renumberParts, resolveConfig, resolveSafeOutputDirs, runInit, scanAndRedactSecrets, stripJsonComments, summarizeJson, summarizeMarkdown, summarizeTypeScriptSource, summarizeWithProfile, supportsTypeScriptImports, truncatePreview, truncateToBytes, unknownPresetMessage, validateSnapshot };
|
|
6458
|
-
//# sourceMappingURL=chunk-
|
|
6459
|
-
//# sourceMappingURL=chunk-
|
|
6461
|
+
//# sourceMappingURL=chunk-L7QBLC4C.js.map
|
|
6462
|
+
//# sourceMappingURL=chunk-L7QBLC4C.js.map
|
package/dist/cli.cjs
CHANGED
|
@@ -5208,6 +5208,9 @@ function validateSnapshot(configInput) {
|
|
|
5208
5208
|
});
|
|
5209
5209
|
}
|
|
5210
5210
|
}
|
|
5211
|
+
const maskValue = (value) => findSecretInPath(value, config.secretRules)?.masked ?? value;
|
|
5212
|
+
const currentExcludes = config.excludePatterns.map(maskValue);
|
|
5213
|
+
const currentInclude = config.include.map(maskValue);
|
|
5211
5214
|
const recorded = manifest.config;
|
|
5212
5215
|
if (recorded && typeof recorded === "object") {
|
|
5213
5216
|
if (recorded.maxPartBytes !== config.maxPartBytes) {
|
|
@@ -5236,15 +5239,15 @@ function validateSnapshot(configInput) {
|
|
|
5236
5239
|
);
|
|
5237
5240
|
}
|
|
5238
5241
|
const recordedExcludes = Array.isArray(recorded.excludePatterns) ? recorded.excludePatterns : [];
|
|
5239
|
-
if (recordedExcludes.join("\0") !==
|
|
5242
|
+
if (recordedExcludes.join("\0") !== currentExcludes.join("\0")) {
|
|
5240
5243
|
drift.configMismatches.push(
|
|
5241
|
-
`excludePatterns: manifest [${recordedExcludes.join(", ")}] vs current [${
|
|
5244
|
+
`excludePatterns: manifest [${recordedExcludes.join(", ")}] vs current [${currentExcludes.join(", ")}]`
|
|
5242
5245
|
);
|
|
5243
5246
|
}
|
|
5244
5247
|
const recordedInclude = Array.isArray(recorded.include) ? recorded.include : [];
|
|
5245
|
-
if (recordedInclude.join("\0") !==
|
|
5248
|
+
if (recordedInclude.join("\0") !== currentInclude.join("\0")) {
|
|
5246
5249
|
drift.configMismatches.push(
|
|
5247
|
-
`include: manifest [${recordedInclude.join(", ")}] vs current [${
|
|
5250
|
+
`include: manifest [${recordedInclude.join(", ")}] vs current [${currentInclude.join(", ")}]`
|
|
5248
5251
|
);
|
|
5249
5252
|
}
|
|
5250
5253
|
if (recorded?.artifacts && typeof recorded.artifacts === "object") {
|
|
@@ -5424,7 +5427,7 @@ function validateSnapshot(configInput) {
|
|
|
5424
5427
|
|
|
5425
5428
|
// src/index.ts
|
|
5426
5429
|
var GENERATOR_NAME = "@ankurhalder/codebase-snapshot";
|
|
5427
|
-
var GENERATOR_VERSION = "4.0.
|
|
5430
|
+
var GENERATOR_VERSION = "4.0.3";
|
|
5428
5431
|
var SCHEMA_VERSION = "3.0.0";
|
|
5429
5432
|
function sha256Hex2(input) {
|
|
5430
5433
|
return crypto__namespace.createHash("sha256").update(input).digest("hex");
|
package/dist/cli.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { parseByteSize, GENERATOR_VERSION, ARTIFACT_NAMES, getPreset, unknownPresetMessage, MIN_MAX_PART_BYTES, loadConfigFileDetailed, resolveConfig, validateSnapshot, explainPath, compareManifests, loadManifest, renderDiffText, generateSnapshot, GENERATOR_NAME, runInit, PromptCancelled, SCHEMA_VERSION, PRESETS, renderExplainText } from './chunk-
|
|
1
|
+
import { parseByteSize, GENERATOR_VERSION, ARTIFACT_NAMES, getPreset, unknownPresetMessage, MIN_MAX_PART_BYTES, loadConfigFileDetailed, resolveConfig, validateSnapshot, explainPath, compareManifests, loadManifest, renderDiffText, generateSnapshot, GENERATOR_NAME, runInit, PromptCancelled, SCHEMA_VERSION, PRESETS, renderExplainText } from './chunk-L7QBLC4C.js';
|
|
2
2
|
import * as fs from 'fs';
|
|
3
3
|
import * as path2 from 'path';
|
|
4
4
|
import { parseArgs } from 'util';
|
package/dist/index.cjs
CHANGED
|
@@ -4306,6 +4306,9 @@ function validateSnapshot(configInput) {
|
|
|
4306
4306
|
});
|
|
4307
4307
|
}
|
|
4308
4308
|
}
|
|
4309
|
+
const maskValue = (value) => findSecretInPath(value, config.secretRules)?.masked ?? value;
|
|
4310
|
+
const currentExcludes = config.excludePatterns.map(maskValue);
|
|
4311
|
+
const currentInclude = config.include.map(maskValue);
|
|
4309
4312
|
const recorded = manifest.config;
|
|
4310
4313
|
if (recorded && typeof recorded === "object") {
|
|
4311
4314
|
if (recorded.maxPartBytes !== config.maxPartBytes) {
|
|
@@ -4334,15 +4337,15 @@ function validateSnapshot(configInput) {
|
|
|
4334
4337
|
);
|
|
4335
4338
|
}
|
|
4336
4339
|
const recordedExcludes = Array.isArray(recorded.excludePatterns) ? recorded.excludePatterns : [];
|
|
4337
|
-
if (recordedExcludes.join("\0") !==
|
|
4340
|
+
if (recordedExcludes.join("\0") !== currentExcludes.join("\0")) {
|
|
4338
4341
|
drift.configMismatches.push(
|
|
4339
|
-
`excludePatterns: manifest [${recordedExcludes.join(", ")}] vs current [${
|
|
4342
|
+
`excludePatterns: manifest [${recordedExcludes.join(", ")}] vs current [${currentExcludes.join(", ")}]`
|
|
4340
4343
|
);
|
|
4341
4344
|
}
|
|
4342
4345
|
const recordedInclude = Array.isArray(recorded.include) ? recorded.include : [];
|
|
4343
|
-
if (recordedInclude.join("\0") !==
|
|
4346
|
+
if (recordedInclude.join("\0") !== currentInclude.join("\0")) {
|
|
4344
4347
|
drift.configMismatches.push(
|
|
4345
|
-
`include: manifest [${recordedInclude.join(", ")}] vs current [${
|
|
4348
|
+
`include: manifest [${recordedInclude.join(", ")}] vs current [${currentInclude.join(", ")}]`
|
|
4346
4349
|
);
|
|
4347
4350
|
}
|
|
4348
4351
|
if (recorded?.artifacts && typeof recorded.artifacts === "object") {
|
|
@@ -5437,7 +5440,7 @@ async function runInit(options) {
|
|
|
5437
5440
|
|
|
5438
5441
|
// src/index.ts
|
|
5439
5442
|
var GENERATOR_NAME = "@ankurhalder/codebase-snapshot";
|
|
5440
|
-
var GENERATOR_VERSION = "4.0.
|
|
5443
|
+
var GENERATOR_VERSION = "4.0.3";
|
|
5441
5444
|
var SCHEMA_VERSION = "3.0.0";
|
|
5442
5445
|
function sha256Hex2(input) {
|
|
5443
5446
|
return crypto__namespace.createHash("sha256").update(input).digest("hex");
|
package/dist/index.d.cts
CHANGED
|
@@ -495,7 +495,7 @@ declare function matchesExclude(relativePath: string, pattern: string): boolean;
|
|
|
495
495
|
declare function collectFiles(cwd: string, options?: CollectOptions): CollectResult;
|
|
496
496
|
|
|
497
497
|
declare const GENERATOR_NAME = "@ankurhalder/codebase-snapshot";
|
|
498
|
-
declare const GENERATOR_VERSION = "4.0.
|
|
498
|
+
declare const GENERATOR_VERSION = "4.0.3";
|
|
499
499
|
declare const SCHEMA_VERSION = "3.0.0";
|
|
500
500
|
interface GenerateOptions {
|
|
501
501
|
/** Compute the full manifest but write nothing to disk. */
|
package/dist/index.d.ts
CHANGED
|
@@ -495,7 +495,7 @@ declare function matchesExclude(relativePath: string, pattern: string): boolean;
|
|
|
495
495
|
declare function collectFiles(cwd: string, options?: CollectOptions): CollectResult;
|
|
496
496
|
|
|
497
497
|
declare const GENERATOR_NAME = "@ankurhalder/codebase-snapshot";
|
|
498
|
-
declare const GENERATOR_VERSION = "4.0.
|
|
498
|
+
declare const GENERATOR_VERSION = "4.0.3";
|
|
499
499
|
declare const SCHEMA_VERSION = "3.0.0";
|
|
500
500
|
interface GenerateOptions {
|
|
501
501
|
/** Compute the full manifest but write nothing to disk. */
|
package/dist/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export { ARTIFACT_NAMES, DEFAULT_ANSWERS, DEFAULT_SECRET_PATTERNS, GENERATOR_NAME, GENERATOR_VERSION, LANGUAGE_PROFILES, MIN_MAX_PART_BYTES, PRESETS, PromptCancelled, SCHEMA_VERSION, anchorForPath, assertReplaceable, assertUsableConfigInput, collectFiles, compareManifests, countLines, defineConfig, detectLanguage, detectPreset, explainPath, fenceForContent, fenceForText, generateProjectTree, generateSnapshot, generateSnapshotAsync, getPreset, globToRegExp, isBinaryBuffer, isBinaryExtension, isBinaryFile, isInteractive, isResolvedConfig, isSensitivePath, listPresetNames, loadConfigFile, loadConfigFileDetailed, loadManifest, markResolvedConfig, matchRule, matchesExclude, normalizeResolvedConfig, parseByteSize, partitionFiles, profileForPath, renderConfig, renderDiffText, renderExplainText, renderMinimalConfig, renumberParts, resolveConfig, resolveSafeOutputDirs, runInit, scanAndRedactSecrets, stripJsonComments, summarizeJson, summarizeMarkdown, summarizeTypeScriptSource, summarizeWithProfile, supportsTypeScriptImports, truncatePreview, truncateToBytes, validateSnapshot } from './chunk-
|
|
1
|
+
export { ARTIFACT_NAMES, DEFAULT_ANSWERS, DEFAULT_SECRET_PATTERNS, GENERATOR_NAME, GENERATOR_VERSION, LANGUAGE_PROFILES, MIN_MAX_PART_BYTES, PRESETS, PromptCancelled, SCHEMA_VERSION, anchorForPath, assertReplaceable, assertUsableConfigInput, collectFiles, compareManifests, countLines, defineConfig, detectLanguage, detectPreset, explainPath, fenceForContent, fenceForText, generateProjectTree, generateSnapshot, generateSnapshotAsync, getPreset, globToRegExp, isBinaryBuffer, isBinaryExtension, isBinaryFile, isInteractive, isResolvedConfig, isSensitivePath, listPresetNames, loadConfigFile, loadConfigFileDetailed, loadManifest, markResolvedConfig, matchRule, matchesExclude, normalizeResolvedConfig, parseByteSize, partitionFiles, profileForPath, renderConfig, renderDiffText, renderExplainText, renderMinimalConfig, renumberParts, resolveConfig, resolveSafeOutputDirs, runInit, scanAndRedactSecrets, stripJsonComments, summarizeJson, summarizeMarkdown, summarizeTypeScriptSource, summarizeWithProfile, supportsTypeScriptImports, truncatePreview, truncateToBytes, validateSnapshot } from './chunk-L7QBLC4C.js';
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
3
3
|
//# sourceMappingURL=index.js.map
|