gitfamiliar 0.10.0 → 0.11.0

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/README.md CHANGED
@@ -12,6 +12,8 @@
12
12
 
13
13
  [Quick Start](#-quick-start) · [Scoring Modes](#-scoring-modes) · [Team Features](#-team-features) · [HTML Dashboard](#-html-dashboard) · [CLI Reference](#-cli-reference)
14
14
 
15
+ ![HTML Dashboard — Scoring tab](img/html_scoring.png)
16
+
15
17
  </div>
16
18
 
17
19
  ---
@@ -23,22 +25,30 @@ Built for engineers joining a new project, it gives you and your team an objecti
23
25
 
24
26
  ## Demo
25
27
 
28
+ Try it instantly without a git repository:
29
+
30
+ ```bash
31
+ npx gitfamiliar --demo # terminal output
32
+ npx gitfamiliar --demo --html # interactive HTML dashboard
33
+ npx gitfamiliar --demo --hotspot # hotspot analysis
34
+ npx gitfamiliar --demo --team # team comparison
26
35
  ```
27
- $ npx gitfamiliar
28
36
 
29
- GitFamiliar my-project (Binary mode)
37
+ The demo uses a fictional project "acme-web-app" with 4 team members:
30
38
 
31
- Overall: 58/172 files (34%)
39
+ ```
40
+ $ npx gitfamiliar --demo
41
+
42
+ GitFamiliar — acme-web-app (Committed mode)
32
43
 
33
- src/
34
- auth/ ████████░░ 80% (4/5 files)
35
- api/ ███░░░░░░░ 30% (6/20 files)
36
- components/ █░░░░░░░░░ 12% (3/25 files)
37
- utils/ ██████████ 100% (8/8 files)
38
- tests/ ░░░░░░░░░░ 0% (0/14 files)
39
- config/ ██████░░░░ 60% (3/5 files)
44
+ Overall: 22/31 files (68%)
40
45
 
41
- Written: 42 files
46
+ .github/ ░░░░░░░░░░ 0% (0/2 files)
47
+ frontend/ █░░░░░░░░░ 15% (1/7 files)
48
+ components/ ░░░░░░░░░░ 0% (0/4 files)
49
+ src/ ██████████ 100% (18/18 files)
50
+ routes/ ██████████ 100% (4/4 files)
51
+ services/ ██████████ 100% (3/3 files)
42
52
  ```
43
53
 
44
54
  Use `--html` to generate an **interactive unified dashboard** in the browser:
@@ -83,7 +93,7 @@ npm install -g gitfamiliar
83
93
 
84
94
  ## Scoring Modes
85
95
 
86
- ### `binary` — default
96
+ ### `committed` — default
87
97
 
88
98
  > Best for: **New team members** tracking onboarding progress.
89
99
 
@@ -93,7 +103,7 @@ Files are "written" or "not written". A file counts as written if you have at le
93
103
  familiarity = written_files / total_files
94
104
  ```
95
105
 
96
- ### `authorship`
106
+ ### `code-coverage`
97
107
 
98
108
  > Best for: **Tech leads** assessing code ownership and bus factor.
99
109
 
@@ -105,7 +115,7 @@ score(project) = sum(your_lines) / sum(all_lines)
105
115
  ```
106
116
 
107
117
  ```bash
108
- gitfamiliar --mode authorship
118
+ gitfamiliar --mode code-coverage
109
119
  ```
110
120
 
111
121
  ### `weighted`
@@ -159,13 +169,13 @@ gitfamiliar --user "Alice" --user "Bob" # specific users
159
169
  gitfamiliar --team # all contributors
160
170
  ```
161
171
 
162
- ### Team Coverage Map
172
+ ### Contributors Per File
163
173
 
164
174
  Visualize bus factor — how many people know each part of the codebase:
165
175
 
166
176
  ```bash
167
- gitfamiliar --team-coverage
168
- gitfamiliar --team-coverage --html
177
+ gitfamiliar --contributors-per-file
178
+ gitfamiliar --contributors-per-file --html
169
179
  ```
170
180
 
171
181
  | Risk Level | Contributors | Meaning |
@@ -181,7 +191,7 @@ Find files that are frequently changed but poorly understood:
181
191
  ```bash
182
192
  gitfamiliar --hotspot # personal hotspots
183
193
  gitfamiliar --hotspot team # team hotspots
184
- gitfamiliar --hotspot --window 30 # last 30 days only
194
+ gitfamiliar --hotspot --since 30 # last 30 days only
185
195
  gitfamiliar --hotspot --html # scatter plot visualization
186
196
  ```
187
197
 
@@ -202,17 +212,19 @@ gitfamiliar --html --mode weighted # unified, weighted as default scorin
202
212
 
203
213
  | Tab | Visualization | Description |
204
214
  |:---|:---|:---|
205
- | **Scoring** | D3 treemap + sub-tabs | Binary, Authorship, Weighted modes with real-time weight sliders |
206
- | **Coverage** | D3 treemap + risk sidebar | Team bus factorhow many people know each area |
207
- | **Multi-User** | D3 treemap + user dropdown | Compare familiarity across all contributors |
215
+ | **Scoring** | D3 treemap + sub-tabs | Committed, Code Coverage, Weighted modes with real-time weight sliders |
216
+ | **Contributors** | D3 treemap + risk sidebar | Contributors per filebus factor risk analysis |
217
+ | **Team** | D3 treemap + user dropdown | Compare familiarity across all contributors |
208
218
  | **Hotspots** | D3 scatter plot + sidebar | High change frequency × low familiarity = risk |
209
219
 
220
+ ![HTML Dashboard — Hotspots tab](img/html_hotspot.png)
221
+
210
222
  ### Individual HTML Reports
211
223
 
212
224
  ```bash
213
225
  gitfamiliar --html --hotspot # hotspot scatter plot only
214
- gitfamiliar --html --team-coverage # coverage treemap only
215
- gitfamiliar --html --team # multi-user treemap only
226
+ gitfamiliar --html --contributors-per-file # contributors treemap only
227
+ gitfamiliar --html --team # team comparison treemap only
216
228
  gitfamiliar --html --user "Alice" --user "Bob" # specific users comparison
217
229
  ```
218
230
 
@@ -255,17 +267,18 @@ third_party/
255
267
  Usage: gitfamiliar [options]
256
268
 
257
269
  Options:
258
- -m, --mode <mode> Scoring mode: binary | authorship | weighted (default: "binary")
259
- -u, --user <user> Git user name/email (repeatable for comparison)
260
- -e, --expiration <policy> Expiration: never | time:Nd | change:N% | combined:Nd:N%
261
- --html Generate HTML report (alone = unified dashboard)
262
- -w, --weights <w1,w2> Weights for weighted mode (must sum to 1.0)
263
- --team Compare all contributors
264
- --team-coverage Show team coverage map (bus factor analysis)
265
- --hotspot [mode] Hotspot analysis: personal (default) or team
266
- --window <days> Time window for hotspot analysis (default: 90)
267
- -V, --version Output version number
268
- -h, --help Display help
270
+ -m, --mode <mode> Scoring mode: committed | code-coverage | weighted (default: "committed")
271
+ -u, --user <user> Git user name/email (repeatable for comparison)
272
+ -e, --expiration <policy> Expiration: never | time:Nd | change:N% | combined:Nd:N%
273
+ --html Generate HTML report (alone = unified dashboard)
274
+ -w, --weights <w1,w2> Weights for weighted mode (must sum to 1.0)
275
+ --team Compare all contributors
276
+ --contributors-per-file Analyze contributors per file (bus factor)
277
+ --hotspot [mode] Hotspot analysis: personal (default) or team
278
+ --since <days> Hotspot analysis period in days (default: 90)
279
+ --demo Show demo with sample data (no git repo needed)
280
+ -V, --version Output version number
281
+ -h, --help Display help
269
282
  ```
270
283
 
271
284
  ---
@@ -276,7 +289,7 @@ Options:
276
289
  import { computeFamiliarity } from 'gitfamiliar';
277
290
 
278
291
  const result = await computeFamiliarity({
279
- mode: 'binary',
292
+ mode: 'committed',
280
293
  expiration: { policy: 'never' },
281
294
  weights: { blame: 0.5, commit: 0.5 },
282
295
  html: false,