uniweb 1.0.1 → 1.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/package.json +7 -7
- package/partials/agents.md +1 -1
- package/src/commands/add.js +1 -1
- package/src/commands/update.js +19 -5
- package/src/framework-index.json +16 -16
- package/src/versions.js +5 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "uniweb",
|
|
3
|
-
"version": "1.0
|
|
3
|
+
"version": "1.1.0",
|
|
4
4
|
"description": "Create structured Vite + React sites with content/code separation",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -34,22 +34,22 @@
|
|
|
34
34
|
"url": "https://github.com/uniweb/cli/issues"
|
|
35
35
|
},
|
|
36
36
|
"engines": {
|
|
37
|
-
"node": ">=
|
|
37
|
+
"node": ">=22.12"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
40
|
"handlebars": "^4.7.8",
|
|
41
41
|
"js-yaml": "^4.1.0",
|
|
42
42
|
"prompts": "^2.4.2",
|
|
43
43
|
"tar": "^7.0.0",
|
|
44
|
-
"@uniweb/schemas": "~1.0.1",
|
|
45
44
|
"@uniweb/semantic-parser": "~1.5.1",
|
|
46
|
-
"@uniweb/core": "~1.0
|
|
47
|
-
"@uniweb/content-writer": "~1.0.1"
|
|
45
|
+
"@uniweb/core": "~1.1.0",
|
|
46
|
+
"@uniweb/content-writer": "~1.0.1",
|
|
47
|
+
"@uniweb/schemas": "~1.0.1"
|
|
48
48
|
},
|
|
49
49
|
"peerDependencies": {
|
|
50
|
+
"@uniweb/content-reader": "~1.2.8",
|
|
50
51
|
"@uniweb/semantic-parser": "~1.5.1",
|
|
51
|
-
"@uniweb/build": "~1.0
|
|
52
|
-
"@uniweb/content-reader": "~1.2.8"
|
|
52
|
+
"@uniweb/build": "~1.1.0"
|
|
53
53
|
},
|
|
54
54
|
"peerDependenciesMeta": {
|
|
55
55
|
"@uniweb/build": {
|
package/partials/agents.md
CHANGED
|
@@ -2801,7 +2801,7 @@ npx uniweb@latest update # apply: align @uniweb/* deps AND refresh A
|
|
|
2801
2801
|
|
|
2802
2802
|
**`npx uniweb@latest update` is the command for bringing a project up to date.** It aligns the project's `@uniweb/*` dependencies *and* this AGENTS.md to the version matrix of the CLI that runs it. Deps and documentation move together — that's the whole point of the verb.
|
|
2803
2803
|
|
|
2804
|
-
**What the version numbers mean.** A patch brings fixes and features; a minor version is where Uniweb puts breaking changes — `update` lists each package that crosses one, so
|
|
2804
|
+
**What the version numbers mean.** A patch brings fixes and features; a minor version is where Uniweb puts breaking changes — `update` lists each package that crosses one, so build and check the project before shipping — and a major is kept for something really big. Dependencies are written as tilde ranges (`~1.0.1`), so `pnpm install` and `pnpm update` never cross a minor on their own. The move from 0.x to 1.0.1 asks nothing of a project that was on the latest 0.x versions — 1.0.1 carried every package's 0.x line over — though `update` marks each package `major · BREAKING`.
|
|
2805
2805
|
|
|
2806
2806
|
> ### ⛔ WRITE `@latest`. A BARE `uniweb update` IS USUALLY A NO-OP, AND IT SAYS SO CONVINCINGLY
|
|
2807
2807
|
>
|
package/src/commands/add.js
CHANGED
|
@@ -1589,7 +1589,7 @@ async function addCi(rootDir, opts, pm = 'pnpm') {
|
|
|
1589
1589
|
}
|
|
1590
1590
|
|
|
1591
1591
|
// Read node version from root package.json engines.node if pinned;
|
|
1592
|
-
// otherwise default to
|
|
1592
|
+
// otherwise default to 22, the framework's own floor (>=22.12).
|
|
1593
1593
|
const rootPkg = JSON.parse(
|
|
1594
1594
|
await readFile(join(rootDir, 'package.json'), 'utf-8').catch(() => '{}')
|
|
1595
1595
|
)
|
package/src/commands/update.js
CHANGED
|
@@ -304,11 +304,13 @@ export function printSurvey(
|
|
|
304
304
|
const r = breakingRows.find((x) => x.name === name)
|
|
305
305
|
log(` ${colors.red}${name}${colors.reset} ${r.current} → ${r.target} ${colors.dim}(${r.bump})${colors.reset}`)
|
|
306
306
|
}
|
|
307
|
+
// ⛔ The second line said "Read their changelogs before shipping" until 2026-10-13,
|
|
308
|
+
// when most packages kept none.
|
|
307
309
|
log(
|
|
308
|
-
` ${colors.dim}A minor version is where Uniweb's breaking changes go
|
|
310
|
+
` ${colors.dim}A minor version is where Uniweb's breaking changes go (a major is rarer still),${colors.reset}`
|
|
309
311
|
)
|
|
310
312
|
log(
|
|
311
|
-
` ${colors.dim}you may need to act on
|
|
313
|
+
` ${colors.dim}so these are releases you may need to act on: build and check before shipping.${colors.reset}`
|
|
312
314
|
)
|
|
313
315
|
}
|
|
314
316
|
log('')
|
|
@@ -374,6 +376,8 @@ export async function update(args = []) {
|
|
|
374
376
|
const depsOnly = args.includes('--deps-only')
|
|
375
377
|
const skipAgents = args.includes('--no-agents') || depsOnly
|
|
376
378
|
const skipDeps = args.includes('--no-deps') || agentsOnly
|
|
379
|
+
// The flag that kept the deps step from running — what the AGENTS.md step's hint names.
|
|
380
|
+
const depsSkippedBy = agentsOnly ? '--agents-only' : skipDeps ? '--no-deps' : null
|
|
377
381
|
const dryRun = args.includes('--dry-run')
|
|
378
382
|
const allowMismatch = args.includes('--allow-mismatch')
|
|
379
383
|
const verbose = args.includes('--verbose')
|
|
@@ -636,6 +640,7 @@ export async function update(args = []) {
|
|
|
636
640
|
hasYes,
|
|
637
641
|
nonInteractive,
|
|
638
642
|
agentsOnly,
|
|
643
|
+
depsSkippedBy,
|
|
639
644
|
depsEdited,
|
|
640
645
|
installRan,
|
|
641
646
|
installPm
|
|
@@ -734,6 +739,7 @@ async function refreshAgents(ctx) {
|
|
|
734
739
|
hasYes,
|
|
735
740
|
nonInteractive,
|
|
736
741
|
agentsOnly,
|
|
742
|
+
depsSkippedBy,
|
|
737
743
|
depsEdited,
|
|
738
744
|
installRan,
|
|
739
745
|
installPm
|
|
@@ -757,13 +763,21 @@ async function refreshAgents(ctx) {
|
|
|
757
763
|
// Re-survey: deps may have just been edited+installed, which clears the
|
|
758
764
|
// declared-deps gate.
|
|
759
765
|
const finalSurvey = await surveyWorkspaceDeps(workspaceDir)
|
|
760
|
-
|
|
766
|
+
// ⭐ A dry run moves no deps, so they still lag here whenever the deps step has
|
|
767
|
+
// something to align — while the run it previews aligns and installs them before
|
|
768
|
+
// this step. Say what that run would do, rather than that this step would skip.
|
|
769
|
+
const onceInstalled = finalSurvey.anyDrift && dryRun && !depsSkippedBy
|
|
770
|
+
if (finalSurvey.anyDrift && !allowMismatch && !onceInstalled) {
|
|
761
771
|
warn('AGENTS.md refresh skipped: workspace deps still lag the CLI.')
|
|
762
772
|
log(
|
|
763
773
|
`${colors.dim}AGENTS.md from v${cliVersion} would document features not in your installed packages.${colors.reset}`
|
|
764
774
|
)
|
|
775
|
+
// ⛔ This always said "Re-run without --no-deps": wrong under --agents-only, and
|
|
776
|
+
// when the deps edit was declined or left to a non-interactive run's plan.
|
|
765
777
|
log(
|
|
766
|
-
|
|
778
|
+
depsSkippedBy
|
|
779
|
+
? `${colors.dim}Re-run without ${colors.reset}${colors.cyan}${depsSkippedBy}${colors.reset}${colors.dim}, or pass ${colors.reset}${colors.cyan}--allow-mismatch${colors.reset}${colors.dim} to override.${colors.reset}`
|
|
780
|
+
: `${colors.dim}Align the deps first — accept the edit, or re-run with ${colors.reset}${colors.cyan}--yes${colors.reset}${colors.dim} — or pass ${colors.reset}${colors.cyan}--allow-mismatch${colors.reset}${colors.dim} to override.${colors.reset}`
|
|
767
781
|
)
|
|
768
782
|
log('')
|
|
769
783
|
if (agentsOnly) process.exit(1)
|
|
@@ -797,7 +811,7 @@ async function refreshAgents(ctx) {
|
|
|
797
811
|
|
|
798
812
|
if (dryRun) {
|
|
799
813
|
info(
|
|
800
|
-
`Dry-run: would ${currentAgentsVersion ? `update AGENTS.md (v${currentAgentsVersion} → v${cliVersion})` : `create AGENTS.md (v${cliVersion})`}${keeping}.`
|
|
814
|
+
`Dry-run: would ${currentAgentsVersion ? `update AGENTS.md (v${currentAgentsVersion} → v${cliVersion})` : `create AGENTS.md (v${cliVersion})`}${keeping}${onceInstalled ? ', once the deps above are installed' : ''}.`
|
|
801
815
|
)
|
|
802
816
|
return 'skipped'
|
|
803
817
|
}
|
package/src/framework-index.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 1,
|
|
3
|
-
"generatedAt": "2026-10-
|
|
3
|
+
"generatedAt": "2026-10-13T18:18:01.170Z",
|
|
4
4
|
"packages": {
|
|
5
5
|
"@uniweb/api": {
|
|
6
|
-
"version": "1.0
|
|
6
|
+
"version": "1.1.0"
|
|
7
7
|
},
|
|
8
8
|
"@uniweb/build": {
|
|
9
|
-
"version": "1.0
|
|
9
|
+
"version": "1.1.0"
|
|
10
10
|
},
|
|
11
11
|
"@uniweb/content-reader": {
|
|
12
12
|
"version": "1.2.8"
|
|
@@ -15,28 +15,28 @@
|
|
|
15
15
|
"version": "1.0.1"
|
|
16
16
|
},
|
|
17
17
|
"@uniweb/core": {
|
|
18
|
-
"version": "1.0
|
|
18
|
+
"version": "1.1.0"
|
|
19
19
|
},
|
|
20
20
|
"@uniweb/frame-bridge": {
|
|
21
|
-
"version": "1.0.
|
|
21
|
+
"version": "1.0.2"
|
|
22
22
|
},
|
|
23
23
|
"@uniweb/icons": {
|
|
24
|
-
"version": "1.0.
|
|
24
|
+
"version": "1.0.2"
|
|
25
25
|
},
|
|
26
26
|
"@uniweb/kit": {
|
|
27
|
-
"version": "1.0
|
|
27
|
+
"version": "1.1.0"
|
|
28
28
|
},
|
|
29
29
|
"@uniweb/loom": {
|
|
30
|
-
"version": "1.0
|
|
30
|
+
"version": "1.1.0"
|
|
31
31
|
},
|
|
32
32
|
"@uniweb/press": {
|
|
33
|
-
"version": "1.0
|
|
33
|
+
"version": "1.1.0"
|
|
34
34
|
},
|
|
35
35
|
"@uniweb/projections": {
|
|
36
|
-
"version": "1.0
|
|
36
|
+
"version": "1.1.0"
|
|
37
37
|
},
|
|
38
38
|
"@uniweb/runtime": {
|
|
39
|
-
"version": "1.0
|
|
39
|
+
"version": "1.1.0"
|
|
40
40
|
},
|
|
41
41
|
"@uniweb/scene": {
|
|
42
42
|
"version": "1.0.1"
|
|
@@ -45,22 +45,22 @@
|
|
|
45
45
|
"version": "1.0.1"
|
|
46
46
|
},
|
|
47
47
|
"@uniweb/scholar": {
|
|
48
|
-
"version": "1.0
|
|
48
|
+
"version": "1.1.0"
|
|
49
49
|
},
|
|
50
50
|
"@uniweb/semantic-parser": {
|
|
51
51
|
"version": "1.5.1"
|
|
52
52
|
},
|
|
53
53
|
"@uniweb/snapshot": {
|
|
54
|
-
"version": "1.0
|
|
54
|
+
"version": "1.1.0"
|
|
55
55
|
},
|
|
56
56
|
"@uniweb/templates": {
|
|
57
|
-
"version": "1.0
|
|
57
|
+
"version": "1.1.0"
|
|
58
58
|
},
|
|
59
59
|
"@uniweb/theming": {
|
|
60
|
-
"version": "1.0
|
|
60
|
+
"version": "1.1.0"
|
|
61
61
|
},
|
|
62
62
|
"@uniweb/unipress": {
|
|
63
|
-
"version": "1.0
|
|
63
|
+
"version": "1.1.0"
|
|
64
64
|
}
|
|
65
65
|
},
|
|
66
66
|
"templates": {
|
package/src/versions.js
CHANGED
|
@@ -98,7 +98,7 @@ export const PNPM_VERSION = '11'
|
|
|
98
98
|
* before Node 22 — pairing it with Node 20 fails at `pnpm install` with
|
|
99
99
|
* `ERR_UNKNOWN_BUILTIN_MODULE` before the build is attempted. That was the
|
|
100
100
|
* default until 2026-07-21, because the CI node major came from the
|
|
101
|
-
* project's `engines.node` and the workspace template
|
|
101
|
+
* project's `engines.node` and the workspace template declared `>=20.19`.
|
|
102
102
|
*
|
|
103
103
|
* Verify with `npm view pnpm@<major> engines` when adding an entry.
|
|
104
104
|
*/
|
|
@@ -153,14 +153,16 @@ export function resolveCiPnpmVersion(rootPkg, installedMajor = null) {
|
|
|
153
153
|
* @param {string|null|undefined} enginesNode — the project's `engines.node`.
|
|
154
154
|
* @param {'pnpm'|'npm'|'yarn'} packageManager
|
|
155
155
|
* @param {string} [pnpmVersion] — the resolved pnpm major, when pnpm.
|
|
156
|
-
* @param {string} [fallback='
|
|
156
|
+
* @param {string} [fallback='22'] — used when engines.node is absent/unparseable:
|
|
157
|
+
* the framework's own floor (`>=22.12`), which a scaffolded project inherits
|
|
158
|
+
* through its `@uniweb/*` dependencies without declaring one.
|
|
157
159
|
* @returns {string} Node major, as a string for YAML interpolation.
|
|
158
160
|
*/
|
|
159
161
|
export function resolveCiNodeVersion(
|
|
160
162
|
enginesNode,
|
|
161
163
|
packageManager,
|
|
162
164
|
pnpmVersion = PNPM_VERSION,
|
|
163
|
-
fallback = '
|
|
165
|
+
fallback = '22'
|
|
164
166
|
) {
|
|
165
167
|
const match = enginesNode ? String(enginesNode).match(/(\d+)/) : null
|
|
166
168
|
const declared = match ? Number(match[1]) : Number(fallback)
|