launch-doctor 0.4.1 → 0.4.2
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 +29 -1
- package/README.md +78 -439
- package/dist/src/banner.d.ts +22 -0
- package/dist/src/banner.js +35 -0
- package/dist/src/bin.cjs +35 -0
- package/dist/src/bin.d.cts +2 -0
- package/dist/src/checks/access.js +8 -0
- package/dist/src/checks/costs.js +6 -0
- package/dist/src/checks/database.js +29 -0
- package/dist/src/checks/payments.js +12 -0
- package/dist/src/checks/secrets.d.ts +26 -1
- package/dist/src/checks/secrets.js +245 -5
- package/dist/src/cli.js +212 -9
- package/dist/src/fixes.d.ts +8 -1
- package/dist/src/fixes.js +31 -10
- package/dist/src/grade.d.ts +8 -1
- package/dist/src/grade.js +13 -0
- package/dist/src/history.js +9 -2
- package/dist/src/hooks-setup.d.ts +26 -0
- package/dist/src/hooks-setup.js +115 -1
- package/dist/src/index.js +6 -1
- package/dist/src/live.js +5 -3
- package/dist/src/prompt.d.ts +23 -0
- package/dist/src/prompt.js +88 -0
- package/dist/src/report.d.ts +12 -1
- package/dist/src/report.js +27 -15
- package/dist/src/short-report.d.ts +59 -0
- package/dist/src/short-report.js +241 -0
- package/dist/src/types.d.ts +27 -0
- package/dist/src/util.d.ts +2 -0
- package/dist/src/util.js +2 -0
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,33 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [0.4.2] - 2026-12-04
|
|
11
|
+
|
|
12
|
+
### Added
|
|
13
|
+
|
|
14
|
+
- **What to do after a key leaks.** Every leaked-key fix prompt (keys in code, in a public variable, in a committed `.env`, in git history and in a live site) now ends with the next steps: check the provider's usage or activity log for someone else's use, run `--history` to find keys in old commits, and after deploying run `scan <url>` to check the live site (each pointer is left out where the finding came from). `LAUNCH_FIXES.md` shows "Rotate the key first" and "Check whether someone used it" links for these findings. The links come from one provider table in the code; a test checks every kind of key has an entry and every link is https. Usage-log links are given only where the page is known (Stripe, OpenAI, OpenRouter, Supabase, AWS, GitHub, SendGrid, Resend); other providers get a general pointer. Launch Doctor only prints the links; it never opens them or contacts a provider.
|
|
15
|
+
- `launch-doctor init --hooks --upgrade` moves the hooks that `init --hooks` installed (Claude Code, Cursor and the git pre-commit hook) onto the current version. It changes only the pinned launch-doctor package in each hook command, shows each line before and after, and leaves other hooks, other settings and the files' formatting alone. Hooks installed without a version are reported, not rewritten.
|
|
16
|
+
- On Node.js older than 22, `launch-doctor` now prints one message (the version found, that it needs 22 or newer, and how to update with the Node.js download page, nvm or fnm) and exits with code 1, instead of crashing with a syntax or import error. The command now starts from `dist/src/bin.cjs`, a small file in old syntax that checks the version before loading the program.
|
|
17
|
+
- **A shorter default report.** The terminal report now shows one verdict line ("NOT READY TO LAUNCH: 6 critical problems", or "Ready, as far as Launch Doctor can tell" with what was checked and what can't be), two grades (Security: secrets, database, access control, payments, AI costs; Launch readiness: email, monitoring, legal, first impressions), the three things to fix first, one "Also:" line with the other counts, and what to do next. The two grades use the same rules as the overall grade, which stays in `--json`; `--json` also gains `grades.security` and `grades.launch`. Findings that can be critical get a consequence-first title for this report ("Anyone can use your Stripe account: the live secret key is in your code"), a short reason, and for leaked keys a link to the provider's page for rotating them. These are in a new `display` field: finding ids, titles, fingerprints and baselines are unchanged.
|
|
18
|
+
- `--verbose` prints the full report (every category and every finding). `--ci`, `--changed`, `--staged`, `--pr-comment`, `scan <url>`, the hooks, the MCP server and pull request comments are unchanged.
|
|
19
|
+
- `launch-doctor prompt <n> [folder]` prints fix prompt n (the numbers in the report and in `LAUNCH_FIXES.md`) and says which finding it is for. `--copy` puts it on the clipboard with clip, pbcopy, wl-copy or xclip; without one, it prints the prompt and says so. No new dependencies.
|
|
20
|
+
- `LAUNCH_FIXES.md` starts with one prompt for all the critical problems.
|
|
21
|
+
- A progress line on scans that take more than a second, only in an interactive terminal, cleared before the report.
|
|
22
|
+
- An empty folder, or a project in a language the checks don't read (Rust, Java or Kotlin, .NET, Flutter, Swift, Elixir, C or C++) with nothing to fix, gets a plain explanation instead of a grade. `--json` and `--ci` are unchanged.
|
|
23
|
+
- An ASCII banner (LAUNCH / DOCTOR in the "ANSI Shadow" style, 51 columns wide) above the title of a full scan: a folder, `--demo` or `scan <url>`. It only shows when stdout is a terminal at least 53 columns wide, and never with `--json`, `--ci`, `--sarif`, `--out`, `--changed`, `--staged` or `--pr-comment`, or when `CI` or `GITHUB_ACTIONS` is set. `--no-banner` turns it off. It is plain text with no colour.
|
|
24
|
+
|
|
25
|
+
### Changed
|
|
26
|
+
|
|
27
|
+
- **A shorter README.** It starts with a five-step quick start, then keeps what a reader needs before trusting a grade ("Read this first", "What it cannot do", "How it is tested"), the checks, the grading and a table of common commands. The full CLI reference, configuration, CI and pull request comments, hooks and the MCP server, the live scan details, the pipeline description and the library API moved, unchanged apart from updated facts, into `docs/cli.md`, `docs/configuration.md`, `docs/ci.md`, `docs/ai-tools.md`, `docs/live-scan.md`, `docs/how-it-works.md` and `docs/library.md`. Facts updated on the way: Node 18 and 20 are now refused with a message, hooks move to a new version with `init --hooks --upgrade`, the test count, where the last recorded grade appears, and what is at the top of `LAUNCH_FIXES.md`. A test checks that every relative link in the README and `docs/` points to a file that exists.
|
|
28
|
+
- `scripts/corpus.mjs` reads the corpus folder from the `LAUNCH_DOCTOR_CORPUS_DIR` environment variable, and uses `.corpus/` in the repository when it is not set, so nothing changes for anyone who does not set it. `diff --check` (and `diff --update`) now exit with code 1 when an app could not be scanned, for example because the folder is wrong, instead of reporting "No difference"; `--update` leaves the snapshot alone in that case. CONTRIBUTING.md describes both.
|
|
29
|
+
- `docs/roadmap.md` is revised: M1 now plans two headline grades (Security and Launch readiness; the old overall grade stays in `--json`), M2 adds checks on AI agent and MCP configs, and new milestones cover deployment config, more frameworks, reliability, polish and strictness presets. `explain` and `compare` are planned in M10, and the list of what is not planned has five more entries with reasons. Nothing in it is built yet.
|
|
30
|
+
- The roadmap now starts with a rule that no new features are built until 0.5.0 is merged, except a "Quick wins" milestone (key rotation guidance, consequence-first titles, a clear message on old Node, `init --hooks --upgrade`, a shorter README). It also adds monorepo support to R2, sign-in and cookie rules and Supabase function listing to M1 and M2, `fix --safe`, an accuracy page and a browser version, and six more entries under "not planned". Nothing in it is built yet.
|
|
31
|
+
- New `docs/coverage.md` maps the checks to the OWASP Top 10 and says plainly what is not covered.
|
|
32
|
+
|
|
33
|
+
### Fixed
|
|
34
|
+
|
|
35
|
+
- A comment that only names a public secret variable ("// don't use VITE_OPENAI_API_KEY") is no longer reported as a critical leak, in code files and in commented-out `.env` lines. A variable used in code is still reported, at the line where it is used. Real key values inside comments are still found.
|
|
36
|
+
|
|
10
37
|
## [0.4.1] - 2026-12-04
|
|
11
38
|
|
|
12
39
|
### Added
|
|
@@ -184,7 +211,8 @@ First release.
|
|
|
184
211
|
- `.launchdoctorignore` for silencing findings by id or skipping paths.
|
|
185
212
|
- Support for JavaScript / TypeScript and Python projects.
|
|
186
213
|
|
|
187
|
-
[Unreleased]: https://github.com/SHARAJ379/Launch-Doctor/compare/v0.4.
|
|
214
|
+
[Unreleased]: https://github.com/SHARAJ379/Launch-Doctor/compare/v0.4.2...HEAD
|
|
215
|
+
[0.4.2]: https://github.com/SHARAJ379/Launch-Doctor/compare/v0.4.1...v0.4.2
|
|
188
216
|
[0.4.1]: https://github.com/SHARAJ379/Launch-Doctor/compare/v0.4.0...v0.4.1
|
|
189
217
|
[0.4.0]: https://github.com/SHARAJ379/Launch-Doctor/compare/v0.3.0...v0.4.0
|
|
190
218
|
[0.3.0]: https://github.com/SHARAJ379/Launch-Doctor/compare/v0.2.1...v0.3.0
|