@piercebarney/whs-eleventy 2026.11.127 → 2027.1.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 +13 -5
- package/cli.js +2 -0
- package/lib/env.js +14 -0
- package/package.json +2 -5
- package/scripts/bundle-standard.js +0 -35
- package/standard/CHANGELOG.md +0 -6892
- package/standard/core.md +0 -2025
package/README.md
CHANGED
|
@@ -9,6 +9,7 @@ whs plan [--next|--check] project work-queue table / next ticket /
|
|
|
9
9
|
whs compliance [--strict] codebase-vs-standard conformance sweep
|
|
10
10
|
whs doctor [--live|--deploy-preflight] infrastructure drift check
|
|
11
11
|
whs site plan|apply [--create] show / apply the Netlify site setup (builds stopped, domain, link, secrets)
|
|
12
|
+
whs env plan|ads on|off check / flip the Netlify env flags (FEATURE_ADS kill switch; checks the AI key, never sets it)
|
|
12
13
|
whs html html-validate (standard preset) over every _site/ page
|
|
13
14
|
whs links built-output link / CSP / JSON-LD integrity
|
|
14
15
|
whs a11y axe-core WCAG 2.2 A/AA scan of _site/
|
|
@@ -61,11 +62,18 @@ const { runRepoChecks, readCache } = require("@piercebarney/whs-eleventy/lib/doc
|
|
|
61
62
|
|
|
62
63
|
`whs compliance`'s drift check reads `core.md` + `CHANGELOG.md` to compare the
|
|
63
64
|
project's `standard-version` pin against the current standard —
|
|
64
|
-
`resolveStandard()` is `@piercebarney/whs-core`'s
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
`MANUAL`, never a
|
|
65
|
+
`resolveStandard()` is `@piercebarney/whs-core`'s. This package bundles no
|
|
66
|
+
standard of its own: the fallback copy is the one `@piercebarney/whs-core`
|
|
67
|
+
carries under its own `standard/`, as of that package's last publish. Override
|
|
68
|
+
with `WHS_STANDARD=/path/to/web-house-style` (the authoring repo points this at
|
|
69
|
+
itself). When neither resolves, the drift row is a visible `MANUAL`, never a
|
|
70
|
+
silent pass.
|
|
71
|
+
|
|
72
|
+
This package's version is its own semver (first `2027.0.0`), bumped by
|
|
73
|
+
`bin/bump-package` at release time and published when it is new — it does not
|
|
74
|
+
track the standard's date pin. A project's tooling range comes from the
|
|
75
|
+
`package.json` version in the standard checkout at its target tag (see
|
|
76
|
+
`/whs:upgrade`).
|
|
69
77
|
|
|
70
78
|
## Not in this package
|
|
71
79
|
|
package/cli.js
CHANGED
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
// whs compliance [--strict] codebase-vs-standard conformance sweep
|
|
7
7
|
// whs doctor [--live|--deploy-preflight] infrastructure drift check
|
|
8
8
|
// whs site plan|apply [--create] show / apply the Netlify site setup (builds stopped, domain, link, secrets)
|
|
9
|
+
// whs env plan|ads on|off check / flip the Netlify env flags (FEATURE_ADS kill switch; checks the AI key, never sets it)
|
|
9
10
|
// whs pre-push <name> <url> pre-push check (secrets, private remote, no deploy); git ref lines on stdin
|
|
10
11
|
// whs html html-validate (standard preset) over every _site/ page
|
|
11
12
|
// whs links built-output link / CSP / JSON-LD integrity
|
|
@@ -26,6 +27,7 @@ const COMMANDS = {
|
|
|
26
27
|
compliance: "compliance.js",
|
|
27
28
|
doctor: "doctor.js",
|
|
28
29
|
site: "site.js",
|
|
30
|
+
env: "env.js",
|
|
29
31
|
"pre-push": "pre-push.js",
|
|
30
32
|
html: "html.js",
|
|
31
33
|
links: "check-links.js",
|
package/lib/env.js
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// `whs env plan|ads on|off` — the Netlify env flags (core.md#config-idiom). The
|
|
2
|
+
// logic is stack-agnostic (@piercebarney/whs-core's lib/env.js); this file
|
|
3
|
+
// supplies the project root, prints, and exits.
|
|
4
|
+
|
|
5
|
+
const { runEnv } = require("@piercebarney/whs-core/lib/env.js");
|
|
6
|
+
const { ROOT } = require("./_project.js");
|
|
7
|
+
|
|
8
|
+
function main() {
|
|
9
|
+
const r = runEnv({ argv: process.argv.slice(2), root: ROOT });
|
|
10
|
+
for (const line of r.lines) console.log(line);
|
|
11
|
+
process.exit(r.exitCode);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
if (require.main === module) main();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@piercebarney/whs-eleventy",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2027.1.0",
|
|
4
4
|
"description": "The web house style's Eleventy + Netlify tooling — the compliance sweep, the infra doctor, the link/CSP integrity check, and the a11y scan, shared by every project on the stack.",
|
|
5
5
|
"bin": {
|
|
6
6
|
"whs": "cli.js"
|
|
@@ -8,12 +8,9 @@
|
|
|
8
8
|
"files": [
|
|
9
9
|
"cli.js",
|
|
10
10
|
"lib/",
|
|
11
|
-
"scripts/",
|
|
12
|
-
"standard/",
|
|
13
11
|
"README.md"
|
|
14
12
|
],
|
|
15
13
|
"scripts": {
|
|
16
|
-
"prepare": "node scripts/bundle-standard.js",
|
|
17
14
|
"lint": "prettier --check . && eslint .",
|
|
18
15
|
"types": "tsc -p .",
|
|
19
16
|
"test": "node --test test/*.test.js",
|
|
@@ -32,7 +29,7 @@
|
|
|
32
29
|
"node": ">=22"
|
|
33
30
|
},
|
|
34
31
|
"dependencies": {
|
|
35
|
-
"@piercebarney/whs-core": "
|
|
32
|
+
"@piercebarney/whs-core": "^2027.1.0",
|
|
36
33
|
"node-html-parser": "^9.0.2"
|
|
37
34
|
},
|
|
38
35
|
"devDependencies": {
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
// Copies the standard's text into standard/ so the published package carries the
|
|
2
|
-
// core.md + CHANGELOG.md the drift check reads. Runs as `prepare` — before
|
|
3
|
-
// `npm pack` / `npm publish`, and on a local `file:` install.
|
|
4
|
-
//
|
|
5
|
-
// Source is the repo root, three levels up (packages/whs-eleventy/scripts →
|
|
6
|
-
// repo). When that isn't there (the package was installed as a git dep, say)
|
|
7
|
-
// but standard/ is already populated, this is a no-op. Never hard-fails an
|
|
8
|
-
// install.
|
|
9
|
-
|
|
10
|
-
const fs = require("node:fs");
|
|
11
|
-
const path = require("node:path");
|
|
12
|
-
|
|
13
|
-
const REPO = path.join(__dirname, "..", "..", "..");
|
|
14
|
-
const OUT = path.join(__dirname, "..", "standard");
|
|
15
|
-
const FILES = ["core.md", "CHANGELOG.md"];
|
|
16
|
-
|
|
17
|
-
const haveSource = FILES.every((f) => fs.existsSync(path.join(REPO, f)));
|
|
18
|
-
const haveBundle = FILES.every((f) => fs.existsSync(path.join(OUT, f)));
|
|
19
|
-
|
|
20
|
-
if (!haveSource) {
|
|
21
|
-
if (haveBundle) {
|
|
22
|
-
console.log("bundle-standard: no repo source, standard/ already populated — skipping");
|
|
23
|
-
process.exit(0);
|
|
24
|
-
}
|
|
25
|
-
console.warn(
|
|
26
|
-
"bundle-standard: no repo source and no bundled standard/ — the drift check will need WHS_STANDARD set",
|
|
27
|
-
);
|
|
28
|
-
process.exit(0);
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
fs.mkdirSync(OUT, { recursive: true });
|
|
32
|
-
for (const f of FILES) {
|
|
33
|
-
fs.copyFileSync(path.join(REPO, f), path.join(OUT, f));
|
|
34
|
-
}
|
|
35
|
-
console.log(`bundle-standard: copied ${FILES.join(", ")} → standard/`);
|