repo-dive 0.15.0 → 0.15.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.
Files changed (2) hide show
  1. package/dist/cli.js +31 -15
  2. package/package.json +4 -4
package/dist/cli.js CHANGED
@@ -42694,7 +42694,7 @@ var runWith = (command, config) => {
42694
42694
  };
42695
42695
  var package_default = {
42696
42696
  name: "repo-dive",
42697
- version: "0.15.0",
42697
+ version: "0.15.1",
42698
42698
  description: "Dive into a git repo's history: per-commit snapshots, an indexed metrics catalog and an interactive dashboard",
42699
42699
  keywords: [
42700
42700
  "git",
@@ -42767,9 +42767,9 @@ var package_default = {
42767
42767
  devDependencies: {
42768
42768
  "@babel/core": "8.0.1",
42769
42769
  "@base-ui/react": "1.7.0",
42770
- "@changesets/changelog-github": "0.7.0",
42771
- "@changesets/cli": "2.31.1",
42772
- "@changesets/config": "3.1.4",
42770
+ "@changesets/changelog-github": "1.0.0",
42771
+ "@changesets/cli": "3.0.0",
42772
+ "@changesets/config": "4.0.0",
42773
42773
  "@effect/platform-node": "4.0.0-beta.106",
42774
42774
  "@effect/vitest": "4.0.0-beta.106",
42775
42775
  "@kachkaev/eslint-config-base": "1.2.0",
@@ -50121,12 +50121,28 @@ var botPattern = /\brenovate\b|\bdependabot\b|github-actions|\[bot\]/i;
50121
50121
  * those letters, like `Kate Talbot`, stay human.
50122
50122
  */
50123
50123
  var botNameSuffixPattern = /[\s-]bot$/i;
50124
- /** Known AI coding agents (mirrors the co-author heuristic in indexing.ts). */
50125
- var aiPattern = /claude|copilot|cursor|chatgpt|openai|gemini|aider|devin|coderabbit|codegen|sweep|windsurf/i;
50124
+ /**
50125
+ * Names AI coding agents sign with, matched against the display name as whole
50126
+ * words so a human name that merely contains one stays human — `Sam Devine`
50127
+ * is not Devin, `Kai Haider` is not aider. `coderabbit` is anchored on
50128
+ * the left only because the agent signs as `coderabbitai`. Claude and Devin
50129
+ * are ordinary given names even as whole words, so those two only count with
50130
+ * the agent/model word agents append (`Claude Opus 4.5`, `Devin AI`).
50131
+ */
50132
+ var aiNamePattern = /\bcopilot\b|\bcursor\b|\bchatgpt\b|\bcodex\b|\bopenai\b|\bgemini\b|\baider\b|\bcoderabbit|\bcodegen\b|\bsweep\b|\bwindsurf\b|\bclaude[\s.-]?(?:ai|code|opus|sonnet|haiku|fable|mythos|\d)\b|\bdevin[\s.-]?ai\b/i;
50133
+ /**
50134
+ * Mailboxes agents commit under — always agent-specific addresses, never a
50135
+ * bare vendor domain: `alice@openai.com` is an employee, not an agent, which
50136
+ * is why product names are never matched against the email side.
50137
+ */
50138
+ var aiEmailPattern = /(?:claude|noreply)@anthropic\.com|(?:chatgpt|codex|noreply)@openai\.com/i;
50126
50139
  /** `"Name <email>"` → `"Name"`; identities without an email part are used as-is. */
50127
50140
  var identityName = (identity) => identity.replace(/\s*<[^<>]*>\s*$/, "").trim();
50128
50141
  /** Classifies a `"Name <email>"` identity when the config leaves `kind` unset. */
50129
- var deriveContributorKind = (identity) => botPattern.test(identity) || botNameSuffixPattern.test(identityName(identity)) ? "bot" : aiPattern.test(identity) ? "ai" : "human";
50142
+ var deriveContributorKind = (identity) => {
50143
+ const name = identityName(identity);
50144
+ return botPattern.test(identity) || botNameSuffixPattern.test(name) ? "bot" : aiNamePattern.test(name) || aiEmailPattern.test(identity) ? "ai" : "human";
50145
+ };
50130
50146
  /**
50131
50147
  * Tidies an auto-derived name for display. The kind badge (🤖 / ✨) already
50132
50148
  * marks bots and AI agents, so the `[bot]` suffix GitHub bakes into author names
@@ -50757,7 +50773,7 @@ var warnAboutIgnoreFiles = ({ repoRoot, config }) => gen(function* () {
50757
50773
  ].join("\n"));
50758
50774
  }).pipe(ignore$1);
50759
50775
  //#endregion
50760
- //#region src/cli/shared/worktree.ts
50776
+ //#region src/cli/shared/scan/with-temporary-worktree.ts
50761
50777
  /**
50762
50778
  * Materializes a commit into a detached temporary worktree, runs `use` and
50763
50779
  * always cleans up. The user's own working tree is never touched: the checkout
@@ -51252,7 +51268,7 @@ var dashboardCommand = make$5("dashboard", {
51252
51268
  open: config.open
51253
51269
  })));
51254
51270
  //#endregion
51255
- //#region src/cli/shared/gc.ts
51271
+ //#region src/cli/gc-command/run-gc.ts
51256
51272
  var readdirIfExists = (dirPath) => tryPromise(async () => {
51257
51273
  try {
51258
51274
  return await readdir(dirPath);
@@ -51476,7 +51492,7 @@ var gcCommand = make$5("gc", {
51476
51492
  yes: config.yes
51477
51493
  })));
51478
51494
  //#endregion
51479
- //#region src/cli/shared/ignore.ts
51495
+ //#region src/cli/ignore-command/run-ignore.ts
51480
51496
  /**
51481
51497
  * Lists the catalog in every ignore file at the repository root that needs it,
51482
51498
  * so the tools reading them stop walking the cache.
@@ -51520,7 +51536,7 @@ var ignoreCommand = make$5("ignore", {
51520
51536
  dryRun: config.dryRun
51521
51537
  })));
51522
51538
  //#endregion
51523
- //#region src/cli/shared/compose-lineage-series.ts
51539
+ //#region src/cli/shared/indexing/compose-lineage-series.ts
51524
51540
  /** Adds `source`'s numeric leaves into `target`, recursing through records. */
51525
51541
  var addValuesInto = (target, source) => {
51526
51542
  for (const [key, value] of Object.entries(source)) {
@@ -51562,7 +51578,7 @@ var composeLineageSeries = (snapshots) => {
51562
51578
  });
51563
51579
  };
51564
51580
  //#endregion
51565
- //#region src/cli/shared/remote.ts
51581
+ //#region src/cli/shared/indexing/remote.ts
51566
51582
  /**
51567
51583
  * Turns whatever `remote.origin.url` holds into a URL a browser can open, or
51568
51584
  * `undefined` when there is nothing to link to (no remote, a local path, an
@@ -56853,7 +56869,7 @@ var runQuery = ({ repoPath, sql, json }) => gen(function* () {
56853
56869
  yield* log(json ? JSON.stringify(result.rows, void 0, 2) : formatTable(result));
56854
56870
  });
56855
56871
  //#endregion
56856
- //#region src/cli/shared/mcp.ts
56872
+ //#region src/cli/mcp-command/build-mcp-layer.ts
56857
56873
  var queryTool = make$3("query", {
56858
56874
  description: "Run a read-only SQL query (SELECT/WITH/EXPLAIN) against the repository's metrics cube. Tables: commits (sha, authored_at, committed_at, author_email, author_name) and facts (commit_sha, collector, metric, value, categories as a JSON object usable via json_extract). Returns { columns, rows, truncated }.",
56859
56875
  parameters: Struct({ sql: String$1 }),
@@ -56939,7 +56955,7 @@ var queryCommand = make$5("query", {
56939
56955
  json: config.json
56940
56956
  })));
56941
56957
  //#endregion
56942
- //#region src/cli/shared/report.ts
56958
+ //#region src/cli/report-command/run-report.ts
56943
56959
  /**
56944
56960
  * Builds a single self-contained report.html: the dashboard bundle with CSS,
56945
56961
  * JS and the repository's dashboard.json inlined — shareable without running
@@ -56999,7 +57015,7 @@ var scanCommand = make$5("scan", {
56999
57015
  force: config.force
57000
57016
  })));
57001
57017
  //#endregion
57002
- //#region src/cli/shared/status.ts
57018
+ //#region src/cli/status-command/run-status.ts
57003
57019
  var exists = (filePath) => promise(() => access(filePath).then(() => true, () => false));
57004
57020
  var runStatus = ({ repoPath }) => gen(function* () {
57005
57021
  const repoRoot = yield* resolveRepoRoot(repoPath);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "repo-dive",
3
- "version": "0.15.0",
3
+ "version": "0.15.1",
4
4
  "description": "Dive into a git repo's history: per-commit snapshots, an indexed metrics catalog and an interactive dashboard",
5
5
  "keywords": [
6
6
  "git",
@@ -54,9 +54,9 @@
54
54
  "devDependencies": {
55
55
  "@babel/core": "8.0.1",
56
56
  "@base-ui/react": "1.7.0",
57
- "@changesets/changelog-github": "0.7.0",
58
- "@changesets/cli": "2.31.1",
59
- "@changesets/config": "3.1.4",
57
+ "@changesets/changelog-github": "1.0.0",
58
+ "@changesets/cli": "3.0.0",
59
+ "@changesets/config": "4.0.0",
60
60
  "@effect/platform-node": "4.0.0-beta.106",
61
61
  "@effect/vitest": "4.0.0-beta.106",
62
62
  "@kachkaev/eslint-config-base": "1.2.0",