@karaoke-cms/assert-privacy 0.9.2 → 0.9.5
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 +9 -13
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -2,20 +2,20 @@
|
|
|
2
2
|
|
|
3
3
|
Post-build privacy gate for karaoke-cms. Scans the built `dist/` directory and fails if any unpublished vault content has leaked into the output.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## Usage
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
Runs automatically as a CI step after `astro build`:
|
|
8
8
|
|
|
9
9
|
```yaml
|
|
10
10
|
# .github/workflows/deploy.yml
|
|
11
|
-
- run:
|
|
11
|
+
- run: npm run build
|
|
12
12
|
- run: node scripts/assert-privacy.js dist
|
|
13
13
|
```
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
Or manually:
|
|
16
16
|
|
|
17
17
|
```bash
|
|
18
|
-
node
|
|
18
|
+
node scripts/assert-privacy.js dist
|
|
19
19
|
```
|
|
20
20
|
|
|
21
21
|
## What it does
|
|
@@ -24,18 +24,14 @@ Walks every `.html` file in the build output and checks:
|
|
|
24
24
|
|
|
25
25
|
- No content from unpublished vault entries (those without `publish: true`) appears in any page
|
|
26
26
|
- The RSS feed at `dist/rss.xml` is well-formed XML
|
|
27
|
-
- No
|
|
27
|
+
- No handbook content leaked into production HTML
|
|
28
28
|
|
|
29
29
|
Exits with code 1 and a clear error message if a violation is found, blocking the deploy.
|
|
30
30
|
|
|
31
31
|
## Status
|
|
32
32
|
|
|
33
|
-
**Stub** — the package
|
|
33
|
+
**Stub** — the package placeholder is installed by scaffolded projects. The implementation lives at `scripts/assert-privacy.js` in your project directory.
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
## What's new in 0.9.5
|
|
36
36
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
- This is the last line of privacy defense before content reaches the CDN. The Astro content filter (`publish: true` in `makeCollections()`) prevents unpublished content from entering the build graph. This package verifies the output, catching edge cases like content injected via wikilinks or manually added pages.
|
|
40
|
-
- In CI, a failed assert blocks the Cloudflare Pages deploy entirely.
|
|
41
|
-
- Running it locally after `pnpm build` is the recommended way to verify privacy before pushing.
|
|
37
|
+
No user-facing changes in this release — version bumped for lockstep with the monorepo.
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@karaoke-cms/assert-privacy",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.9.
|
|
4
|
+
"version": "0.9.5",
|
|
5
5
|
"description": "Post-build privacy gate for karaoke-cms",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"astro",
|
|
@@ -9,6 +9,6 @@
|
|
|
9
9
|
"privacy"
|
|
10
10
|
],
|
|
11
11
|
"scripts": {
|
|
12
|
-
"test": "echo \"No tests yet — source lives in apps/
|
|
12
|
+
"test": "echo \"No tests yet — source lives in apps/website/scripts/\""
|
|
13
13
|
}
|
|
14
|
-
}
|
|
14
|
+
}
|