@anirudw/repolens 0.2.3 → 0.3.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/index.js CHANGED
@@ -1,5 +1,4 @@
1
1
  #!/usr/bin/env node
2
- import "./chunk-PE6PHNN5.js";
3
2
 
4
3
  // src/cli/commands.ts
5
4
  import { Command } from "commander";
@@ -244,7 +243,7 @@ async function ensureLoaded() {
244
243
  const [ts, js, tst] = await Promise.all([
245
244
  import("tree-sitter"),
246
245
  import("tree-sitter-javascript"),
247
- import("./node-EEBHCXXR.js")
246
+ import("tree-sitter-typescript")
248
247
  ]);
249
248
  TreeSitterParser = ts.default;
250
249
  JavaScript = js.default;
@@ -1012,23 +1011,22 @@ function createCommand() {
1012
1011
  graph.calculateHealthMetrics();
1013
1012
  if (options.health) {
1014
1013
  const nodes = Array.from(graph.getNodes().values());
1015
- console.log("Total nodes:", nodes.length);
1016
1014
  const topCoreDeps = nodes.sort((a, b) => b.ca - a.ca).slice(0, 5).filter((n) => n.ca > 0);
1017
1015
  const topUnstable = nodes.sort((a, b) => b.instability - a.instability).slice(0, 5).filter((n) => n.instability > 0);
1018
- console.log("\n=== Architectural Health Metrics ===\n");
1019
- console.log("Core deps count:", topCoreDeps.length);
1020
- console.log("Unstable count:", topUnstable.length);
1016
+ console.log(pc.bold("\n=== Architectural Health Metrics ===\n"));
1021
1017
  if (topCoreDeps.length > 0) {
1022
- console.log("\nTop 5 Core Dependencies:");
1018
+ console.log(pc.bold("Top 5 Core Dependencies (Highest Ca - will break most things if changed):"));
1023
1019
  for (const node of topCoreDeps) {
1024
- console.log(` ${node.relativePath}: ${node.ca} dependents`);
1020
+ console.log(` ${pc.red(node.relativePath)}: ${pc.bold(node.ca.toString())} dependents`);
1025
1021
  }
1022
+ console.log();
1026
1023
  }
1027
1024
  if (topUnstable.length > 0) {
1028
- console.log("\nTop 5 Unstable Files:");
1025
+ console.log(pc.bold("Top 5 Most Unstable Files (Highest I = Ce/(Ca+Ce)):"));
1029
1026
  for (const node of topUnstable) {
1030
- console.log(` ${node.relativePath}: ${node.instability.toFixed(3)} instability`);
1027
+ console.log(` ${pc.yellow(node.relativePath)}: ${pc.bold(node.instability.toFixed(3))} instability`);
1031
1028
  }
1029
+ console.log();
1032
1030
  }
1033
1031
  process.exit(0);
1034
1032
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@anirudw/repolens",
3
- "version": "0.2.3",
3
+ "version": "0.3.1",
4
4
  "description": "A CLI tool to visualize repository dependency graphs",
5
5
  "type": "module",
6
6
  "bin": {
@@ -1,26 +0,0 @@
1
- #!/usr/bin/env node
2
- var __getOwnPropNames = Object.getOwnPropertyNames;
3
- var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
4
- get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
5
- }) : x)(function(x) {
6
- if (typeof require !== "undefined") return require.apply(this, arguments);
7
- throw Error('Dynamic require of "' + x + '" is not supported');
8
- });
9
- var __glob = (map) => (path) => {
10
- var fn = map[path];
11
- if (fn) return fn();
12
- throw new Error("Module not found in bundle: " + path);
13
- };
14
- var __esm = (fn, res) => function __init() {
15
- return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
16
- };
17
- var __commonJS = (cb, mod) => function __require2() {
18
- return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
19
- };
20
-
21
- export {
22
- __require,
23
- __glob,
24
- __esm,
25
- __commonJS
26
- };