codechart 0.4.0 → 0.6.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/CHANGELOG.md +68 -0
- package/README.md +5 -5
- package/dist/cli.js +2442 -1353
- package/dist/server.js +349 -0
- package/package.json +3 -2
- package/skills/codechart/SKILL.md +2 -0
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
What's new in each codechart release. Update with `codechart update`; the [releases page](https://github.com/freeleex/codechart/releases) has the same notes.
|
|
4
|
+
|
|
5
|
+
## 0.6.0 (2026-11-06)
|
|
6
|
+
|
|
7
|
+
### New
|
|
8
|
+
|
|
9
|
+
- HTML: Light/Full switch in the header, remembered per browser. Light keeps the short diff preview; Full shows every change of a node so you can review without going back to your IDE.
|
|
10
|
+
- HTML Full: hunks are foldable per file, with a `‹ 4 / 7 ›` stepper, `+ all` / `− all`; keys `n`/`p` hunk, `]`/`[` unreviewed node, `r` reviewed, `o`/`O` fold, `?` help.
|
|
11
|
+
- HTML: review ticks, the `Reviewed` box and the `x/y reviewed` bar now live in Full mode.
|
|
12
|
+
|
|
13
|
+
### Changed
|
|
14
|
+
|
|
15
|
+
- Lockfiles, minified bundles, `dist/` and files marked `linguist-generated` show "generated file, not shown" instead of their diff. Full mode shows up to 1000 lines per file.
|
|
16
|
+
- HTML diffs: the `+`/`−` sign has its own column and long lines wrap under the code, keeping their indent.
|
|
17
|
+
|
|
18
|
+
## 0.5.0 (2026-11-05)
|
|
19
|
+
|
|
20
|
+
### New
|
|
21
|
+
|
|
22
|
+
- `codechart doctor` checks your setup for each agent (skill, reminder line, Stop hook, OpenCode plugin, CLI version); `--fix` repairs what's broken, `--last` explains why the last turn got no diagram.
|
|
23
|
+
- OpenCode plugin: OpenCode 2 now gets the same "3+ files changed and no map" nudge as Claude Code. `install-skill` adds it, `--no-plugin` skips it.
|
|
24
|
+
- HTML: selecting a node lights up its neighbours and dims the rest; the side panel lists its relations, each one a link.
|
|
25
|
+
- HTML: status chips under the header are the legend and a filter; click one to fade that status, `Δ changes only` fades unchanged nodes.
|
|
26
|
+
- HTML: tick nodes as reviewed, with an `x/y reviewed` count and `Next ▸`; ticks are kept per browser and reset when a node's diff changes.
|
|
27
|
+
|
|
28
|
+
## 0.4.0 (2026-11-05)
|
|
29
|
+
|
|
30
|
+
### New
|
|
31
|
+
|
|
32
|
+
- Maps in pull and merge requests: the map and its check overview in the description, re-rendered by CI on every push (GitHub and GitLab); set up with `setup-pr-maps`, see [PR maps](https://github.com/freeleex/codechart/blob/main/docs/pr-maps.md).
|
|
33
|
+
- `codechart update` installs the newest version and refreshes your skill copies and reminder lines; a once-a-day notice says when there is one (off with `updateCheck: false`).
|
|
34
|
+
- Summary maps flag changed files that no node covers, and say when the diff wasn't checked.
|
|
35
|
+
- HTML: browser Back/Forward and ← → buttons walk the nodes you opened; `#node=<id>` links open a node.
|
|
36
|
+
- Terminal map: status marker in a gutter (`+ invoices`), one block per node, and `--md` uses a `diff` fence so agents' chats colour new and removed lines.
|
|
37
|
+
- `install-skill` adds the reminder line and Claude Code hook by default (`--no-reminder`, `--no-hook` to skip) and updates older codechart skill copies in place.
|
|
38
|
+
|
|
39
|
+
### Fixed
|
|
40
|
+
|
|
41
|
+
- File and class nodes no longer look the same: map cards show the kind and a shape per kind.
|
|
42
|
+
- Labels that read as code (`_l([...])`) fail validation with a request to use plain words.
|
|
43
|
+
- Each check mismatch now says in plain words what it means.
|
|
44
|
+
|
|
45
|
+
## 0.3.1 (2026-11-03)
|
|
46
|
+
|
|
47
|
+
### Changed
|
|
48
|
+
|
|
49
|
+
- Security review fixes; see [security review](https://github.com/freeleex/codechart/blob/main/docs/security-review.md).
|
|
50
|
+
- Faster previews on big diffs (100 files: 1.8 s → 0.1 s) and shorter agent output (one error per missing file).
|
|
51
|
+
|
|
52
|
+
## 0.3.0 (2026-11-03)
|
|
53
|
+
|
|
54
|
+
### New
|
|
55
|
+
|
|
56
|
+
- Infrastructure maps: Terraform, OpenTofu, Terragrunt, Helm, Kustomize and Kubernetes changes get a map through the built-in `infrastructure` path rule.
|
|
57
|
+
- Now/After pages show two panes only when they differ, with a `Panes: linked/separate` toggle.
|
|
58
|
+
- Listed on skills.sh; the skill says to run `npm i -g codechart` when the CLI is missing.
|
|
59
|
+
|
|
60
|
+
## 0.2.0 (2026-11-03)
|
|
61
|
+
|
|
62
|
+
### New
|
|
63
|
+
|
|
64
|
+
- Map nodes are checked against the code (file exists, quoted line matches, in the diff for summaries); output leads with the check result.
|
|
65
|
+
- Plans that change existing code render Now and After side by side, for maps and flows.
|
|
66
|
+
- Node panel shows the file's diff; the panel is wider, resizable and wraps code.
|
|
67
|
+
- Each map picks top-down or left-to-right layout, whichever fits.
|
|
68
|
+
- Opt-in reminder line and Claude Code Stop hook (`install-skill --hook`).
|
package/README.md
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
<p align="center">
|
|
9
9
|
<a href="https://www.npmjs.com/package/codechart"><img alt="npm" src="https://img.shields.io/npm/v/codechart"></a>
|
|
10
10
|
<a href="https://github.com/freeleex/codechart/actions/workflows/ci.yml"><img alt="CI" src="https://github.com/freeleex/codechart/actions/workflows/ci.yml/badge.svg"></a>
|
|
11
|
-
<a href="https://skills.sh/freeleex/codechart"><img alt="skills.sh" src="https://
|
|
11
|
+
<a href="https://skills.sh/freeleex/codechart"><img alt="skills.sh" src="https://skills.sh/b/freeleex/codechart"></a>
|
|
12
12
|
<img alt="Node 22.12+" src="https://img.shields.io/badge/node-%3E%3D22.12-339933">
|
|
13
13
|
<a href="LICENSE"><img alt="MIT" src="https://img.shields.io/badge/license-MIT-blue"></a>
|
|
14
14
|
</p>
|
|
@@ -85,7 +85,7 @@ That's it. Open your coding agent in any repo and try:
|
|
|
85
85
|
> show me the flow of accepting an invite
|
|
86
86
|
```
|
|
87
87
|
|
|
88
|
-
Works with Claude Code, Codex, Gemini CLI, GitHub Copilot, Cursor, OpenCode and any other agent that supports [Agent Skills](https://agentskills.io). `install-skill` asks which agents get the skill, and adds a reminder line
|
|
88
|
+
Works with Claude Code, Codex, Gemini CLI, GitHub Copilot, Cursor, OpenCode and any other agent that supports [Agent Skills](https://agentskills.io). `install-skill` asks which agents get the skill, and adds a reminder line, a Claude Code hook and an OpenCode plugin so agents don't forget it in long sessions. `codechart update` brings everything up to date (what changed: [CHANGELOG.md](CHANGELOG.md)), and codechart tells you once a day when there's a new version. No diagram appeared? `codechart doctor` checks the setup (`--fix` repairs it, `--last` explains the last turn). Details, other agents, updating and uninstalling: [Install and agents](docs/install.md).
|
|
89
89
|
|
|
90
90
|
## What you get
|
|
91
91
|
|
|
@@ -153,7 +153,7 @@ On the full page, a changed resource shows its HCL diff and changed attributes (
|
|
|
153
153
|
|
|
154
154
|
### Terminal first, page when it helps
|
|
155
155
|
|
|
156
|
-
Small diagrams stay in the reply. Big ones also get a self-contained HTML page: zoom, pan, light and dark themes, a node panel with back/forward through the nodes you opened, nothing loaded from the internet. In a change summary, a node's diff is read from git when the page is built, so the agent spends no tokens on it.
|
|
156
|
+
Small diagrams stay in the reply. Big ones also get a self-contained HTML page: zoom, pan, light and dark themes, a node panel with back/forward through the nodes you opened and a list of the node's links (selecting a node dims all but it and its neighbours; Esc clears), a row of status chips under the header that count, explain and fade nodes (*Δ changes only* hides the context), nothing loaded from the internet. In a change summary, a node's diff is read from git when the page is built, so the agent spends no tokens on it (lockfiles, minified bundles, `dist/` and files marked `linguist-generated` are skipped). A header switch picks **Light** (default: the first 3 hunks of each diff, with a *see all in Full* hint) or **Full**: the whole diff (up to 1000 lines per file) as foldable hunks, tickboxes to mark nodes reviewed (*7/12 reviewed*, *Next unreviewed*; a tick lasts until the node's diff changes) a pager bar (‹ 3 / 10 ›, *+ all* / *− all*) and keys: `n`/`p` hunks (open one, fold the rest), `]`/`[` unreviewed nodes, `r` reviewed, `o`/`O` fold, `?` help.
|
|
157
157
|
|
|
158
158
|
### Maps in pull requests
|
|
159
159
|
|
|
@@ -184,11 +184,11 @@ The skill fires when the agent summarizes a change, writes a plan or explains ho
|
|
|
184
184
|
|
|
185
185
|
A diagram is about **2–3 extra API calls**. In a long session that's roughly 2–3% of your usage per diagram, and nothing for trivial changes. That's an estimate from Claude Code sessions with Sonnet; other agents and models will differ, and shorter sessions pay proportionally more. Measured runs are in [docs/efficiency.md](docs/efficiency.md).
|
|
186
186
|
|
|
187
|
-
The CLI is small: a
|
|
187
|
+
The CLI is small: a 110.3 kB package, 5 runtime dependencies, and a cold start around 150 ms.
|
|
188
188
|
|
|
189
189
|
## Safe to run
|
|
190
190
|
|
|
191
|
-
- No telemetry, no shell: only read-only `git` and your OS opener. The only network calls are a once-a-day version check to npm ([off with one setting](docs/install.md#updating)) and opt-in [PR maps](docs/pr-maps.md), whose CI job edits the PR description and publishes the map image.
|
|
191
|
+
- No telemetry, no shell: only read-only `git` and your OS opener. The only network calls are a once-a-day version check to npm, plus a read of the changelog from GitHub when there's a newer one ([off with one setting](docs/install.md#updating)) and opt-in [PR maps](docs/pr-maps.md), whose CI job edits the PR description and publishes the map image.
|
|
192
192
|
- HTML pages load nothing external, all text is escaped, and they're saved to `~/.cache/codechart`, never to your repo. A summary page holds your diff: share it only where you'd share the diff.
|
|
193
193
|
- Audited before release across 8 areas, including untrusted repos and prompt-injected specs: [SECURITY.md](SECURITY.md) and [docs/security-review.md](docs/security-review.md).
|
|
194
194
|
|