ssqch 0.7.1 → 0.9.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.
Files changed (155) hide show
  1. package/README.md +8 -4
  2. package/bin/ssqch.js +14 -48
  3. package/bundled/README.md +1314 -0
  4. package/bundled/completions/bash +840 -0
  5. package/bundled/completions/elvish +286 -0
  6. package/bundled/completions/fish +182 -0
  7. package/bundled/completions/powershell +318 -0
  8. package/bundled/completions/zsh +510 -0
  9. package/bundled/ssqch.d.ts +540 -0
  10. package/bundled/starter/engines/index.edge +11 -0
  11. package/bundled/starter/engines/index.ejs +11 -0
  12. package/bundled/starter/engines/index.hbs +11 -0
  13. package/bundled/starter/engines/index.liquid +11 -0
  14. package/bundled/starter/engines/layout.edge +35 -0
  15. package/bundled/starter/engines/layout.ejs +35 -0
  16. package/bundled/starter/engines/layout.hbs +35 -0
  17. package/bundled/starter/engines/layout.liquid +35 -0
  18. package/bundled/starter/gitignore +3 -0
  19. package/bundled/starter/jsconfig.json +11 -0
  20. package/bundled/starter/src/404.md +8 -0
  21. package/bundled/starter/src/_blueprints/posts.md +5 -0
  22. package/bundled/starter/src/_data/site.json +4 -0
  23. package/bundled/starter/src/_includes/layout.jinja +35 -0
  24. package/bundled/starter/src/index.jinja +11 -0
  25. package/bundled/starter/src/posts/i-know-what-i-saw.md +11 -0
  26. package/bundled/starter/src/posts/posts.json +4 -0
  27. package/bundled/starter/src/posts/raiders-of-the-lost-path.md +27 -0
  28. package/bundled/starter/src/posts/the-cache-of-the-wild.md +26 -0
  29. package/bundled/starter/src/posts/the-stump-has-moved.md +15 -0
  30. package/bundled/starter/src/posts/upon-further-review-a-stump.md +18 -0
  31. package/bundled/starter/ssqch.config.js +29 -0
  32. package/bundled/starter-docs/engines/edge/base.edge +41 -0
  33. package/bundled/starter-docs/engines/edge/containers/details.edge +5 -0
  34. package/bundled/starter-docs/engines/edge/containers/tab.edge +4 -0
  35. package/bundled/starter-docs/engines/edge/containers/tabs.edge +5 -0
  36. package/bundled/starter-docs/engines/edge/doc.edge +59 -0
  37. package/bundled/starter-docs/engines/edge/hooks/heading.edge +2 -0
  38. package/bundled/starter-docs/engines/ejs/base.ejs +41 -0
  39. package/bundled/starter-docs/engines/ejs/containers/details.ejs +5 -0
  40. package/bundled/starter-docs/engines/ejs/containers/tab.ejs +4 -0
  41. package/bundled/starter-docs/engines/ejs/containers/tabs.ejs +5 -0
  42. package/bundled/starter-docs/engines/ejs/doc.ejs +59 -0
  43. package/bundled/starter-docs/engines/ejs/hooks/heading.ejs +2 -0
  44. package/bundled/starter-docs/engines/hbs/base.hbs +41 -0
  45. package/bundled/starter-docs/engines/hbs/containers/details.hbs +5 -0
  46. package/bundled/starter-docs/engines/hbs/containers/tab.hbs +4 -0
  47. package/bundled/starter-docs/engines/hbs/containers/tabs.hbs +5 -0
  48. package/bundled/starter-docs/engines/hbs/doc.hbs +58 -0
  49. package/bundled/starter-docs/engines/hbs/hooks/heading.hbs +2 -0
  50. package/bundled/starter-docs/engines/liquid/base.liquid +41 -0
  51. package/bundled/starter-docs/engines/liquid/containers/details.liquid +5 -0
  52. package/bundled/starter-docs/engines/liquid/containers/tab.liquid +4 -0
  53. package/bundled/starter-docs/engines/liquid/containers/tabs.liquid +5 -0
  54. package/bundled/starter-docs/engines/liquid/doc.liquid +60 -0
  55. package/bundled/starter-docs/engines/liquid/hooks/heading.liquid +2 -0
  56. package/bundled/starter-docs/gitignore +4 -0
  57. package/bundled/starter-docs/src/404.md +12 -0
  58. package/bundled/starter-docs/src/_blueprints/docs.md +5 -0
  59. package/bundled/starter-docs/src/_data/nav.yml +10 -0
  60. package/bundled/starter-docs/src/_data/site.json +5 -0
  61. package/bundled/starter-docs/src/_includes/base.jinja +41 -0
  62. package/bundled/starter-docs/src/_includes/containers/details.jinja +5 -0
  63. package/bundled/starter-docs/src/_includes/containers/tab.jinja +4 -0
  64. package/bundled/starter-docs/src/_includes/containers/tabs.jinja +5 -0
  65. package/bundled/starter-docs/src/_includes/doc.jinja +59 -0
  66. package/bundled/starter-docs/src/_includes/hooks/heading.jinja +2 -0
  67. package/bundled/starter-docs/src/assets/docs.css +257 -0
  68. package/bundled/starter-docs/src/assets/docs.js +67 -0
  69. package/bundled/starter-docs/src/docs/docs.json +1 -0
  70. package/bundled/starter-docs/src/docs/guides/deploying.md +77 -0
  71. package/bundled/starter-docs/src/docs/guides/writing.md +65 -0
  72. package/bundled/starter-docs/src/docs/index.md +29 -0
  73. package/bundled/starter-docs/src/docs/install.md +42 -0
  74. package/bundled/starter-docs/src/index.md +13 -0
  75. package/bundled/starter-docs/ssqch.config.js +40 -0
  76. package/bundled/trailheads/from-component-frameworks.md +116 -0
  77. package/bundled/trailheads/from-docusaurus.md +55 -0
  78. package/bundled/trailheads/from-eleventy.md +140 -0
  79. package/bundled/trailheads/from-hexo.md +92 -0
  80. package/bundled/trailheads/from-jekyll.md +79 -0
  81. package/bundled/trailheads/from-mkdocs.md +45 -0
  82. package/bundled/trailheads/from-zola.md +71 -0
  83. package/lib/assets.js +235 -3
  84. package/lib/chunk-3A647I3N.js +384 -0
  85. package/lib/chunk-3GYLOC6Y.js +1017 -0
  86. package/lib/chunk-3K3ANWZ2.js +118 -0
  87. package/lib/chunk-3NYSSA2C.js +22 -0
  88. package/lib/chunk-47P4YREZ.js +1287 -0
  89. package/lib/chunk-4Q6WMTER.js +32 -0
  90. package/lib/chunk-76NTVE34.js +338 -0
  91. package/lib/chunk-7PWCYHTJ.js +1350 -0
  92. package/lib/chunk-7RDRZHJD.js +217 -0
  93. package/lib/chunk-7SD7K567.js +57 -0
  94. package/lib/chunk-7XLK2GEG.js +54 -0
  95. package/lib/chunk-AD3HAW3W.js +10 -0
  96. package/lib/chunk-BEGC7YP6.js +502 -0
  97. package/lib/chunk-CMUWRPSQ.js +113 -0
  98. package/lib/chunk-CZ4XQC56.js +999 -0
  99. package/lib/chunk-D2XE2GTY.js +71 -0
  100. package/lib/chunk-DDV6JEC2.js +46 -0
  101. package/lib/chunk-DELWRJAO.js +37409 -0
  102. package/lib/chunk-DELWRJAO.js.LEGAL.txt +27 -0
  103. package/lib/chunk-F65YUXZ7.js +334 -0
  104. package/lib/chunk-FVZ5JBRI.js +115 -0
  105. package/lib/chunk-GRWMGC7D.js +4435 -0
  106. package/lib/chunk-GRWMGC7D.js.LEGAL.txt +41 -0
  107. package/lib/chunk-GUKSZ2XM.js +207 -0
  108. package/lib/chunk-HPXAZ2HU.js +251 -0
  109. package/lib/chunk-HXCLCXRT.js +20 -0
  110. package/lib/chunk-I3PS26CI.js +48 -0
  111. package/lib/chunk-IAFM5ITE.js +11 -0
  112. package/lib/chunk-II5DEH3Q.js +209 -0
  113. package/lib/chunk-IJWHOFRP.js +44 -0
  114. package/lib/chunk-LPHNACE4.js +29 -0
  115. package/lib/chunk-MI6EJWA2.js +175 -0
  116. package/lib/chunk-NCWFYT74.js +1541 -0
  117. package/lib/chunk-NKXEPHRZ.js +136 -0
  118. package/lib/chunk-NNUKIGOO.js +160 -0
  119. package/lib/chunk-R7K3D5W5.js +3957 -0
  120. package/lib/chunk-RNJFPFXE.js +29 -0
  121. package/lib/chunk-SF4I6Z7S.js +25 -0
  122. package/lib/chunk-SURPOAW7.js +44 -0
  123. package/lib/chunk-SXMJ52IK.js +572 -0
  124. package/lib/chunk-TICWN55Z.js +20 -0
  125. package/lib/chunk-TVU3OPPK.js +146 -0
  126. package/lib/chunk-UU43WIZG.js +29 -0
  127. package/lib/chunk-VJWQSYEG.js +119 -0
  128. package/lib/chunk-XMXBHXZR.js +75 -0
  129. package/lib/chunk-YTHQBMDJ.js +211 -0
  130. package/lib/cli.js +547 -0
  131. package/lib/elements.js +180 -3
  132. package/lib/image.js +27 -3
  133. package/lib/links.js +464 -3
  134. package/lib/minify.js +69 -3
  135. package/lib/redirects.js +152 -3
  136. package/lib/rss.js +139 -3
  137. package/lib/sass.js +256 -3
  138. package/lib/sitemap.js +113 -3
  139. package/lib/ssqch.js +28 -0
  140. package/package.json +83 -80
  141. package/src/serve/live.js +174 -0
  142. package/src/serve/not-found.html +31 -0
  143. package/types/globals.d.ts +3 -2
  144. package/types/image.d.ts +7 -3
  145. package/types/index.d.ts +28 -9
  146. package/types/links.d.ts +1 -1
  147. package/types/minify.d.ts +1 -1
  148. package/types/rss.d.ts +1 -1
  149. package/types/sass.d.ts +1 -1
  150. package/types/sitemap.d.ts +2 -0
  151. package/wasm/markdown.wasm +0 -0
  152. package/wasm/minify.wasm +0 -0
  153. package/wasm/sass.wasm +0 -0
  154. package/lib/index.js +0 -3
  155. package/platforms.json +0 -6
@@ -0,0 +1,318 @@
1
+
2
+ using namespace System.Management.Automation
3
+ using namespace System.Management.Automation.Language
4
+
5
+ Register-ArgumentCompleter -Native -CommandName 'ssqch' -ScriptBlock {
6
+ param($wordToComplete, $commandAst, $cursorPosition)
7
+
8
+ $commandElements = $commandAst.CommandElements
9
+ $command = @(
10
+ 'ssqch'
11
+ for ($i = 1; $i -lt $commandElements.Count; $i++) {
12
+ $element = $commandElements[$i]
13
+ if ($element -isnot [StringConstantExpressionAst] -or
14
+ $element.StringConstantType -ne [StringConstantType]::BareWord -or
15
+ $element.Value.StartsWith('-') -or
16
+ $element.Value -eq $wordToComplete) {
17
+ break
18
+ }
19
+ $element.Value
20
+ }) -join ';'
21
+
22
+ $completions = @(switch ($command) {
23
+ 'ssqch' {
24
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
25
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
26
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
27
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
28
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
29
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
30
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
31
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
32
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
33
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
34
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
35
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
36
+ [CompletionResult]::new('-V', '-V ', [CompletionResultType]::ParameterName, 'Print version')
37
+ [CompletionResult]::new('--version', '--version', [CompletionResultType]::ParameterName, 'Print version')
38
+ [CompletionResult]::new('build', 'build', [CompletionResultType]::ParameterValue, 'Build the site (default)')
39
+ [CompletionResult]::new('serve', 'serve', [CompletionResultType]::ParameterValue, 'Build, serve, watch for changes and live-reload the browser')
40
+ [CompletionResult]::new('new', 'new', [CompletionResultType]::ParameterValue, 'Create a page from a blueprint (a file in _blueprints/), with its title and date filled in')
41
+ [CompletionResult]::new('inspect', 'inspect', [CompletionResultType]::ParameterValue, 'Show where a page comes from, and which level of the data cascade set each value')
42
+ [CompletionResult]::new('completions', 'completions', [CompletionResultType]::ParameterValue, 'Print a completion script for your shell, so Tab finishes commands and options')
43
+ [CompletionResult]::new('diff', 'diff', [CompletionResultType]::ParameterValue, 'Compare two builds of a site: URLs added and removed, and what changed on each page')
44
+ [CompletionResult]::new('footprint', 'footprint', [CompletionResultType]::ParameterValue, 'Show how much a build weighs: its files by kind, and the heaviest pages and files')
45
+ [CompletionResult]::new('init', 'init', [CompletionResultType]::ParameterValue, 'Create a starter site (config, layout, five posts, data and editor types)')
46
+ [CompletionResult]::new('types', 'types', [CompletionResultType]::ParameterValue, 'Write ssqch.d.ts, the types editors use for ssqch.config.js')
47
+ [CompletionResult]::new('import', 'import', [CompletionResultType]::ParameterValue, 'Move a site from another generator: rename and rewrite what''s mechanical, and list the rest')
48
+ [CompletionResult]::new('capabilities', 'capabilities', [CompletionResultType]::ParameterValue, 'Say what this binary supports: template languages, modules, config options and optional features')
49
+ [CompletionResult]::new('docs', 'docs', [CompletionResultType]::ParameterValue, 'Read the documentation for this version: a command, config option, function or topic')
50
+ [CompletionResult]::new('help', 'help', [CompletionResultType]::ParameterValue, 'Print this message or the help of the given subcommand(s)')
51
+ break
52
+ }
53
+ 'ssqch;build' {
54
+ [CompletionResult]::new('--format', '--format', [CompletionResultType]::ParameterName, 'text or json')
55
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
56
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
57
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
58
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
59
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
60
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
61
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
62
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
63
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
64
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
65
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
66
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
67
+ break
68
+ }
69
+ 'ssqch;serve' {
70
+ [CompletionResult]::new('-p', '-p', [CompletionResultType]::ParameterName, 'The port to listen on (0 picks a free one)')
71
+ [CompletionResult]::new('--port', '--port', [CompletionResultType]::ParameterName, 'The port to listen on (0 picks a free one)')
72
+ [CompletionResult]::new('--ready-file', '--ready-file', [CompletionResultType]::ParameterName, 'Write this file once the first build is done: JSON with the url, port and output folder')
73
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
74
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
75
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
76
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
77
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
78
+ [CompletionResult]::new('--built', '--built', [CompletionResultType]::ParameterName, 'Serve the output folder as it was built: no build, no watching, no reload script, gzip on')
79
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
80
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
81
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
82
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
83
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
84
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
85
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
86
+ break
87
+ }
88
+ 'ssqch;new' {
89
+ [CompletionResult]::new('--title', '--title', [CompletionResultType]::ParameterName, 'The page''s title (default: from the file''s name)')
90
+ [CompletionResult]::new('--date', '--date', [CompletionResultType]::ParameterName, 'The page''s date, as it''s written in front matter (default: today)')
91
+ [CompletionResult]::new('--blueprint', '--blueprint', [CompletionResultType]::ParameterName, 'The blueprint to use (default: the page''s folder, then `default`)')
92
+ [CompletionResult]::new('--set', '--set', [CompletionResultType]::ParameterName, 'Another front matter key, with its value as it''s written there (repeatable)')
93
+ [CompletionResult]::new('--format', '--format', [CompletionResultType]::ParameterName, 'text or json')
94
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
95
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
96
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
97
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
98
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
99
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
100
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
101
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
102
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
103
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
104
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
105
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
106
+ break
107
+ }
108
+ 'ssqch;inspect' {
109
+ [CompletionResult]::new('--field', '--field', [CompletionResultType]::ParameterName, 'One field of its data, in full, with every level that set it (a dotted path reaches inside: hero.alt)')
110
+ [CompletionResult]::new('--format', '--format', [CompletionResultType]::ParameterName, 'text or json')
111
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
112
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
113
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
114
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
115
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
116
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
117
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
118
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
119
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
120
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
121
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
122
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
123
+ break
124
+ }
125
+ 'ssqch;completions' {
126
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
127
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
128
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
129
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
130
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
131
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
132
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
133
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
134
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
135
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
136
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
137
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
138
+ break
139
+ }
140
+ 'ssqch;diff' {
141
+ [CompletionResult]::new('--ignore', '--ignore', [CompletionResultType]::ParameterName, 'Leave out text matching this regular expression before comparing (repeatable)')
142
+ [CompletionResult]::new('--only', '--only', [CompletionResultType]::ParameterName, 'Only compare files matching this glob, like ''**/*.html'' (repeatable)')
143
+ [CompletionResult]::new('--lines', '--lines', [CompletionResultType]::ParameterName, 'Changed lines to show for each file (0 for all)')
144
+ [CompletionResult]::new('--format', '--format', [CompletionResultType]::ParameterName, 'text or json')
145
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
146
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
147
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
148
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
149
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
150
+ [CompletionResult]::new('--exact', '--exact', [CompletionResultType]::ParameterName, 'Compare bytes: don''t match fingerprinted files or ignore whitespace')
151
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
152
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
153
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
154
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
155
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
156
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
157
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
158
+ break
159
+ }
160
+ 'ssqch;footprint' {
161
+ [CompletionResult]::new('--top', '--top', [CompletionResultType]::ParameterName, 'How many of the heaviest pages and files to list (0 for none)')
162
+ [CompletionResult]::new('--format', '--format', [CompletionResultType]::ParameterName, 'text or json')
163
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
164
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
165
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
166
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
167
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
168
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
169
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
170
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
171
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
172
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
173
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
174
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
175
+ break
176
+ }
177
+ 'ssqch;init' {
178
+ [CompletionResult]::new('--starter', '--starter', [CompletionResultType]::ParameterName, 'What to start with: site (a small blog) or docs (documentation with a sidebar, tabs and search)')
179
+ [CompletionResult]::new('--engine', '--engine', [CompletionResultType]::ParameterName, 'The template language for the starter''s layouts and templates: jinja, njk, edge, liquid, hbs or ejs')
180
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
181
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
182
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
183
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
184
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
185
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
186
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
187
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
188
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
189
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
190
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
191
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
192
+ break
193
+ }
194
+ 'ssqch;types' {
195
+ [CompletionResult]::new('--out', '--out', [CompletionResultType]::ParameterName, 'Where to write it')
196
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
197
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
198
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
199
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
200
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
201
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
202
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
203
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
204
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
205
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
206
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
207
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
208
+ break
209
+ }
210
+ 'ssqch;import' {
211
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
212
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
213
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
214
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
215
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
216
+ [CompletionResult]::new('--write', '--write', [CompletionResultType]::ParameterName, 'Make the changes (without it, only list them)')
217
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
218
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
219
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
220
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
221
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
222
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
223
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
224
+ break
225
+ }
226
+ 'ssqch;capabilities' {
227
+ [CompletionResult]::new('--format', '--format', [CompletionResultType]::ParameterName, 'text or json')
228
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
229
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
230
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
231
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
232
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
233
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
234
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
235
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
236
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
237
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
238
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
239
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
240
+ break
241
+ }
242
+ 'ssqch;docs' {
243
+ [CompletionResult]::new('--from', '--from', [CompletionResultType]::ParameterName, 'Another generator''s words and ssqch''s names for them: eleventy, hugo, jekyll, zola, ...')
244
+ [CompletionResult]::new('--format', '--format', [CompletionResultType]::ParameterName, 'text or json')
245
+ [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
246
+ [CompletionResult]::new('-o', '-o', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
247
+ [CompletionResult]::new('--output', '--output', [CompletionResultType]::ParameterName, 'Override the output directory (relative to the root)')
248
+ [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
249
+ [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
250
+ [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
251
+ [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
252
+ [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
253
+ [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
254
+ [CompletionResult]::new('--verbose', '--verbose', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
255
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
256
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
257
+ break
258
+ }
259
+ 'ssqch;help' {
260
+ [CompletionResult]::new('build', 'build', [CompletionResultType]::ParameterValue, 'Build the site (default)')
261
+ [CompletionResult]::new('serve', 'serve', [CompletionResultType]::ParameterValue, 'Build, serve, watch for changes and live-reload the browser')
262
+ [CompletionResult]::new('new', 'new', [CompletionResultType]::ParameterValue, 'Create a page from a blueprint (a file in _blueprints/), with its title and date filled in')
263
+ [CompletionResult]::new('inspect', 'inspect', [CompletionResultType]::ParameterValue, 'Show where a page comes from, and which level of the data cascade set each value')
264
+ [CompletionResult]::new('completions', 'completions', [CompletionResultType]::ParameterValue, 'Print a completion script for your shell, so Tab finishes commands and options')
265
+ [CompletionResult]::new('diff', 'diff', [CompletionResultType]::ParameterValue, 'Compare two builds of a site: URLs added and removed, and what changed on each page')
266
+ [CompletionResult]::new('footprint', 'footprint', [CompletionResultType]::ParameterValue, 'Show how much a build weighs: its files by kind, and the heaviest pages and files')
267
+ [CompletionResult]::new('init', 'init', [CompletionResultType]::ParameterValue, 'Create a starter site (config, layout, five posts, data and editor types)')
268
+ [CompletionResult]::new('types', 'types', [CompletionResultType]::ParameterValue, 'Write ssqch.d.ts, the types editors use for ssqch.config.js')
269
+ [CompletionResult]::new('import', 'import', [CompletionResultType]::ParameterValue, 'Move a site from another generator: rename and rewrite what''s mechanical, and list the rest')
270
+ [CompletionResult]::new('capabilities', 'capabilities', [CompletionResultType]::ParameterValue, 'Say what this binary supports: template languages, modules, config options and optional features')
271
+ [CompletionResult]::new('docs', 'docs', [CompletionResultType]::ParameterValue, 'Read the documentation for this version: a command, config option, function or topic')
272
+ [CompletionResult]::new('help', 'help', [CompletionResultType]::ParameterValue, 'Print this message or the help of the given subcommand(s)')
273
+ break
274
+ }
275
+ 'ssqch;help;build' {
276
+ break
277
+ }
278
+ 'ssqch;help;serve' {
279
+ break
280
+ }
281
+ 'ssqch;help;new' {
282
+ break
283
+ }
284
+ 'ssqch;help;inspect' {
285
+ break
286
+ }
287
+ 'ssqch;help;completions' {
288
+ break
289
+ }
290
+ 'ssqch;help;diff' {
291
+ break
292
+ }
293
+ 'ssqch;help;footprint' {
294
+ break
295
+ }
296
+ 'ssqch;help;init' {
297
+ break
298
+ }
299
+ 'ssqch;help;types' {
300
+ break
301
+ }
302
+ 'ssqch;help;import' {
303
+ break
304
+ }
305
+ 'ssqch;help;capabilities' {
306
+ break
307
+ }
308
+ 'ssqch;help;docs' {
309
+ break
310
+ }
311
+ 'ssqch;help;help' {
312
+ break
313
+ }
314
+ })
315
+
316
+ $completions.Where{ $_.CompletionText -like "$wordToComplete*" } |
317
+ Sort-Object -Property ListItemText
318
+ }