uniweb 0.56.6 → 0.56.7
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 +8 -8
- package/src/commands/add.js +0 -100
- package/src/framework-index.json +3 -2
- package/src/index.js +74 -23
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "uniweb",
|
|
3
|
-
"version": "0.56.
|
|
3
|
+
"version": "0.56.7",
|
|
4
4
|
"description": "Create structured Vite + React sites with content/code separation",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -41,17 +41,17 @@
|
|
|
41
41
|
"js-yaml": "^4.1.0",
|
|
42
42
|
"prompts": "^2.4.2",
|
|
43
43
|
"tar": "^7.0.0",
|
|
44
|
-
"@uniweb/content-writer": "^0.3.4",
|
|
45
44
|
"@uniweb/core": "^0.29.4",
|
|
46
|
-
"@uniweb/
|
|
47
|
-
"@uniweb/semantic-parser": "^1.4.1",
|
|
45
|
+
"@uniweb/runtime": "^0.26.4",
|
|
48
46
|
"@uniweb/schemas": "^0.3.1",
|
|
49
|
-
"@uniweb/
|
|
47
|
+
"@uniweb/content-writer": "^0.3.4",
|
|
48
|
+
"@uniweb/kit": "^0.19.3",
|
|
49
|
+
"@uniweb/semantic-parser": "^1.4.1"
|
|
50
50
|
},
|
|
51
51
|
"peerDependencies": {
|
|
52
|
-
"@uniweb/
|
|
53
|
-
"@uniweb/
|
|
54
|
-
"@uniweb/
|
|
52
|
+
"@uniweb/build": "^0.52.6",
|
|
53
|
+
"@uniweb/content-reader": "^1.2.5",
|
|
54
|
+
"@uniweb/semantic-parser": "^1.4.1"
|
|
55
55
|
},
|
|
56
56
|
"peerDependenciesMeta": {
|
|
57
57
|
"@uniweb/build": {
|
package/src/commands/add.js
CHANGED
|
@@ -209,11 +209,6 @@ export async function add(rawArgs) {
|
|
|
209
209
|
const nonInteractive = isNonInteractive(rawArgs)
|
|
210
210
|
const args = stripNonInteractiveFlag(rawArgs)
|
|
211
211
|
|
|
212
|
-
if (args[0] === '--help' || args[0] === '-h') {
|
|
213
|
-
showAddHelp()
|
|
214
|
-
return
|
|
215
|
-
}
|
|
216
|
-
|
|
217
212
|
const pm = detectPackageManager()
|
|
218
213
|
const prefix = getCliPrefix()
|
|
219
214
|
|
|
@@ -1821,98 +1816,3 @@ function parseNodeMajor(engines) {
|
|
|
1821
1816
|
return match ? match[1] : null
|
|
1822
1817
|
}
|
|
1823
1818
|
|
|
1824
|
-
/**
|
|
1825
|
-
* Show help for the add command.
|
|
1826
|
-
*
|
|
1827
|
-
* ⚠️ CURRENTLY UNREACHABLE, and the second copy of this text is the cost.
|
|
1828
|
-
* `src/index.js` short-circuits ANY `--help` in the args before dispatching
|
|
1829
|
-
* (its comment says why — `deploy --help` used to open a browser), and `add`
|
|
1830
|
-
* has a dedicated block in that file's HELP map, so `printCommandHelp('add')`
|
|
1831
|
-
* always wins and the `args[0] === '--help'` guard above never fires.
|
|
1832
|
-
*
|
|
1833
|
-
* ⛔ Which means a flag documented here and not there is documented nowhere.
|
|
1834
|
-
* Measured 2026-09-16, when `--starter` was added to both: this copy's
|
|
1835
|
-
* unescaped backticks around \`content:\` closed the template literal and broke
|
|
1836
|
-
* the WHOLE module — every `uniweb add` subcommand failed with "missing ) after
|
|
1837
|
-
* argument list" — and `uniweb add --help` printed correctly throughout,
|
|
1838
|
-
* because it never reaches this function.
|
|
1839
|
-
*/
|
|
1840
|
-
function showAddHelp() {
|
|
1841
|
-
log(`
|
|
1842
|
-
${colors.cyan}${colors.bright}Uniweb Add${colors.reset}
|
|
1843
|
-
|
|
1844
|
-
Add projects, foundations, sites, extensions, section types, or CI workflows to your workspace.
|
|
1845
|
-
|
|
1846
|
-
${colors.bright}Usage:${colors.reset}
|
|
1847
|
-
uniweb add project [name] [options]
|
|
1848
|
-
uniweb add foundation [name] [options]
|
|
1849
|
-
uniweb add site [name] [options]
|
|
1850
|
-
uniweb add extension <name> [options]
|
|
1851
|
-
uniweb add section <name> [options]
|
|
1852
|
-
uniweb add ci [options]
|
|
1853
|
-
|
|
1854
|
-
${colors.bright}Common Options:${colors.reset}
|
|
1855
|
-
--from <template> Apply content from a template after scaffolding
|
|
1856
|
-
--path <dir> Custom directory for the package
|
|
1857
|
-
|
|
1858
|
-
${colors.bright}Foundation Options:${colors.reset}
|
|
1859
|
-
--project <name> Group under a project directory (co-located layout)
|
|
1860
|
-
|
|
1861
|
-
${colors.bright}Site Options:${colors.reset}
|
|
1862
|
-
--foundation <n> Foundation to wire to (prompted if multiple exist)
|
|
1863
|
-
--project <name> Group under a project directory (co-located layout)
|
|
1864
|
-
|
|
1865
|
-
${colors.bright}Extension Options:${colors.reset}
|
|
1866
|
-
--site <name> Site to wire extension URL into
|
|
1867
|
-
|
|
1868
|
-
${colors.bright}Section Options:${colors.reset}
|
|
1869
|
-
--foundation <n> Foundation to add section to (prompted if multiple exist)
|
|
1870
|
-
--starter Generate starter content from the section's \`content:\`
|
|
1871
|
-
declaration — what an author would begin editing. Works on
|
|
1872
|
-
a section that already exists (nothing is written), and on
|
|
1873
|
-
a new one (the scaffold gets a matching declaration)
|
|
1874
|
-
--preset <name> Frontmatter the starter content with this preset's params
|
|
1875
|
-
--write <file> Write the starter markdown to a file instead of printing it
|
|
1876
|
-
--json Emit the content structure and ProseMirror doc instead
|
|
1877
|
-
|
|
1878
|
-
${colors.bright}CI Options:${colors.reset}
|
|
1879
|
-
--host <name> github-pages | cloudflare-pages | netlify | vercel
|
|
1880
|
-
(prompted when omitted)
|
|
1881
|
-
--target <what> site (default) | foundation
|
|
1882
|
-
'foundation' publishes built foundations at permanent
|
|
1883
|
-
versioned URLs — the free alternative to the catalog
|
|
1884
|
-
--site <name> Site the workflow builds (prompted if multiple exist)
|
|
1885
|
-
--foundation <name> With --target foundation: publish just this one
|
|
1886
|
-
--domain <host> Custom domain (GitHub Pages: writes CNAME, serves at root)
|
|
1887
|
-
--project-name <name> Name to register under on the host (default: the
|
|
1888
|
-
workspace name; Cloudflare Pages project, etc.)
|
|
1889
|
-
--no-previews Skip the per-PR preview workflow
|
|
1890
|
-
--force Overwrite an existing workflow file
|
|
1891
|
-
|
|
1892
|
-
${colors.dim}Hosts that support PR previews: cloudflare-pages, netlify, vercel.
|
|
1893
|
-
GitHub Pages has no preview environment, so it scaffolds a deploy workflow only.${colors.reset}
|
|
1894
|
-
|
|
1895
|
-
${colors.bright}Examples:${colors.reset}
|
|
1896
|
-
uniweb add project docs # Create docs/foundation/ + docs/site/
|
|
1897
|
-
uniweb add project docs --from academic # Co-located pair + academic content
|
|
1898
|
-
uniweb add foundation # Create ./foundation/ at root
|
|
1899
|
-
uniweb add foundation ui # Create ./foundations/ui/
|
|
1900
|
-
uniweb add site # Create ./site/ at root
|
|
1901
|
-
uniweb add site blog --foundation marketing # Create ./sites/blog/ wired to marketing
|
|
1902
|
-
uniweb add extension effects --site site # Create ./extensions/effects/
|
|
1903
|
-
uniweb add section Hero # Create Hero section type
|
|
1904
|
-
uniweb add section Hero --foundation ui # Target specific foundation
|
|
1905
|
-
uniweb add section Hero --starter # Starter content for an existing Hero
|
|
1906
|
-
uniweb add section Pricing --starter # Scaffold Pricing + content that fills it
|
|
1907
|
-
uniweb add section Hero --starter --preset split # Frontmatter it with the 'split' preset
|
|
1908
|
-
uniweb add section Hero --starter --json # The structure + ProseMirror, for a script
|
|
1909
|
-
uniweb add foundation --project docs # Create ./docs/foundation/ (co-located)
|
|
1910
|
-
uniweb add site --project docs # Create ./docs/site/ (co-located)
|
|
1911
|
-
uniweb add ci # Pick a host, add a deploy workflow
|
|
1912
|
-
uniweb add ci --host github-pages --site marketing # Pick host + site explicitly
|
|
1913
|
-
uniweb add ci --host netlify # Deploy + PR-preview workflows
|
|
1914
|
-
uniweb add ci --host vercel --no-previews # Deploy workflow only
|
|
1915
|
-
uniweb add ci --domain mysite.com # Custom domain → writes CNAME + UNIWEB_BASE=/
|
|
1916
|
-
uniweb add ci --target foundation # Publish foundations at versioned URLs
|
|
1917
|
-
`)
|
|
1918
|
-
}
|
package/src/framework-index.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": 1,
|
|
3
|
-
"generatedAt": "2026-09-16T20:
|
|
3
|
+
"generatedAt": "2026-09-16T20:57:12.370Z",
|
|
4
4
|
"packages": {
|
|
5
5
|
"@uniweb/api": {
|
|
6
6
|
"version": "0.3.6",
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
]
|
|
11
11
|
},
|
|
12
12
|
"@uniweb/build": {
|
|
13
|
-
"version": "0.52.
|
|
13
|
+
"version": "0.52.6",
|
|
14
14
|
"path": "framework/build",
|
|
15
15
|
"deps": [
|
|
16
16
|
"@uniweb/content-reader",
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
"@uniweb/core",
|
|
19
19
|
"@uniweb/projections",
|
|
20
20
|
"@uniweb/runtime",
|
|
21
|
+
"@uniweb/runtime",
|
|
21
22
|
"@uniweb/schemas",
|
|
22
23
|
"@uniweb/semantic-parser",
|
|
23
24
|
"@uniweb/theming"
|
package/src/index.js
CHANGED
|
@@ -1498,31 +1498,82 @@ ${colors.bright}Options:${colors.reset}
|
|
|
1498
1498
|
--platform <name> (Deprecated alias for --host)
|
|
1499
1499
|
`,
|
|
1500
1500
|
add: `
|
|
1501
|
-
${colors.cyan}${colors.bright}
|
|
1501
|
+
${colors.cyan}${colors.bright}Uniweb Add${colors.reset}
|
|
1502
1502
|
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
add
|
|
1507
|
-
add
|
|
1508
|
-
add
|
|
1509
|
-
add
|
|
1503
|
+
Add projects, foundations, sites, extensions, section types, or CI workflows to your workspace.
|
|
1504
|
+
|
|
1505
|
+
${colors.bright}Usage:${colors.reset}
|
|
1506
|
+
uniweb add project [name] [options]
|
|
1507
|
+
uniweb add foundation [name] [options]
|
|
1508
|
+
uniweb add site [name] [options]
|
|
1509
|
+
uniweb add extension <name> [options]
|
|
1510
|
+
uniweb add section <name> [options]
|
|
1511
|
+
uniweb add ci [options]
|
|
1512
|
+
|
|
1513
|
+
${colors.bright}Common Options:${colors.reset}
|
|
1514
|
+
--from <template> Apply content from a template after scaffolding
|
|
1515
|
+
--path <dir> Custom directory for the package
|
|
1516
|
+
--non-interactive Fail with usage info instead of prompting
|
|
1517
|
+
|
|
1518
|
+
${colors.bright}Foundation Options:${colors.reset}
|
|
1519
|
+
--project <name> Group under a project directory (co-located layout)
|
|
1520
|
+
|
|
1521
|
+
${colors.bright}Site Options:${colors.reset}
|
|
1522
|
+
--foundation <n> Foundation to wire to (prompted if multiple exist)
|
|
1523
|
+
--project <name> Group under a project directory (co-located layout)
|
|
1524
|
+
|
|
1525
|
+
${colors.bright}Extension Options:${colors.reset}
|
|
1526
|
+
--site <name> Site to wire extension URL into
|
|
1527
|
+
|
|
1528
|
+
${colors.bright}Section Options:${colors.reset}
|
|
1529
|
+
--foundation <n> Foundation to add section to (prompted if multiple exist)
|
|
1530
|
+
--starter Generate starter content from the section's \`content:\`
|
|
1531
|
+
declaration — what an author would begin editing. Works on
|
|
1532
|
+
a section that already exists (nothing is written), and on
|
|
1533
|
+
a new one (the scaffold gets a matching declaration)
|
|
1534
|
+
--preset <name> Frontmatter the starter content with this preset's params
|
|
1535
|
+
--write <file> Write the starter markdown to a file instead of printing it
|
|
1536
|
+
--json Emit the content structure and ProseMirror doc instead
|
|
1537
|
+
|
|
1538
|
+
${colors.bright}CI Options:${colors.reset}
|
|
1539
|
+
--host <name> github-pages | cloudflare-pages | netlify | vercel
|
|
1540
|
+
(prompted when omitted)
|
|
1541
|
+
--target <what> site (default) | foundation
|
|
1542
|
+
'foundation' publishes built foundations at permanent
|
|
1543
|
+
versioned URLs — the free alternative to the catalog
|
|
1544
|
+
--site <name> Site the workflow builds (prompted if multiple exist)
|
|
1545
|
+
--foundation <name> With --target foundation: publish just this one
|
|
1546
|
+
--domain <host> Custom domain (GitHub Pages: writes CNAME, serves at root)
|
|
1547
|
+
--project-name <name> Name to register under on the host (default: the
|
|
1548
|
+
workspace name; Cloudflare Pages project, etc.)
|
|
1549
|
+
--no-previews Skip the per-PR preview workflow
|
|
1550
|
+
--force Overwrite an existing workflow file
|
|
1551
|
+
|
|
1552
|
+
${colors.dim}Hosts that support PR previews: cloudflare-pages, netlify, vercel.
|
|
1553
|
+
GitHub Pages has no preview environment, so it scaffolds a deploy workflow only.${colors.reset}
|
|
1510
1554
|
|
|
1511
|
-
${colors.bright}
|
|
1512
|
-
|
|
1513
|
-
--
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
|
|
1520
|
-
|
|
1521
|
-
|
|
1522
|
-
|
|
1523
|
-
--preset
|
|
1524
|
-
--
|
|
1525
|
-
|
|
1555
|
+
${colors.bright}Examples:${colors.reset}
|
|
1556
|
+
uniweb add project docs # Create docs/foundation/ + docs/site/
|
|
1557
|
+
uniweb add project docs --from academic # Co-located pair + academic content
|
|
1558
|
+
uniweb add foundation # Create ./foundation/ at root
|
|
1559
|
+
uniweb add foundation ui # Create ./foundations/ui/
|
|
1560
|
+
uniweb add site # Create ./site/ at root
|
|
1561
|
+
uniweb add site blog --foundation marketing # Create ./sites/blog/ wired to marketing
|
|
1562
|
+
uniweb add extension effects --site site # Create ./extensions/effects/
|
|
1563
|
+
uniweb add section Hero # Create Hero section type
|
|
1564
|
+
uniweb add section Hero --foundation ui # Target specific foundation
|
|
1565
|
+
uniweb add section Hero --starter # Starter content for an existing Hero
|
|
1566
|
+
uniweb add section Pricing --starter # Scaffold Pricing + content that fills it
|
|
1567
|
+
uniweb add section Hero --starter --preset split # Frontmatter it with the 'split' preset
|
|
1568
|
+
uniweb add section Hero --starter --json # The structure + ProseMirror, for a script
|
|
1569
|
+
uniweb add foundation --project docs # Create ./docs/foundation/ (co-located)
|
|
1570
|
+
uniweb add site --project docs # Create ./docs/site/ (co-located)
|
|
1571
|
+
uniweb add ci # Pick a host, add a deploy workflow
|
|
1572
|
+
uniweb add ci --host github-pages --site marketing # Pick host + site explicitly
|
|
1573
|
+
uniweb add ci --host netlify # Deploy + PR-preview workflows
|
|
1574
|
+
uniweb add ci --host vercel --no-previews # Deploy workflow only
|
|
1575
|
+
uniweb add ci --domain mysite.com # Custom domain → writes CNAME + UNIWEB_BASE=/
|
|
1576
|
+
uniweb add ci --target foundation # Publish foundations at versioned URLs
|
|
1526
1577
|
`,
|
|
1527
1578
|
export: `
|
|
1528
1579
|
${colors.cyan}${colors.bright}uniweb export${colors.reset} ${colors.dim}— Export a self-contained site for third-party hosting${colors.reset}
|