ssqch 0.10.0 → 0.11.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 (95) hide show
  1. package/bundled/completions/bash +62 -16
  2. package/bundled/completions/elvish +28 -12
  3. package/bundled/completions/fish +36 -23
  4. package/bundled/completions/powershell +30 -12
  5. package/bundled/completions/zsh +40 -19
  6. package/bundled/docs/agents.md +12 -1
  7. package/bundled/docs/build-summary.md +31 -1
  8. package/bundled/docs/comparing-builds.md +37 -5
  9. package/bundled/docs/configuring.md +30 -5
  10. package/bundled/docs/field-guide.md +1 -1
  11. package/bundled/docs/github-pages.md +1 -1
  12. package/bundled/docs/index.md +1 -1
  13. package/bundled/docs/known-gaps.md +1 -1
  14. package/bundled/docs/markdown.md +63 -5
  15. package/bundled/docs/multilingual.md +20 -3
  16. package/bundled/docs/nav.yml +1 -0
  17. package/bundled/docs/netlify.md +2 -2
  18. package/bundled/docs/plugins.md +4 -4
  19. package/bundled/docs/seo.md +39 -1
  20. package/bundled/docs/template-languages.md +6 -4
  21. package/bundled/docs/templates.md +3 -3
  22. package/bundled/docs/trailheads/from-eleventy.md +25 -13
  23. package/bundled/docs/trailheads/from-hugo.md +103 -0
  24. package/bundled/docs/trailheads/from-jekyll.md +49 -15
  25. package/bundled/docs/trailheads/from-mkdocs.md +54 -9
  26. package/bundled/docs/trailheads/from-zola.md +2 -2
  27. package/bundled/docs/trailheads.md +22 -5
  28. package/bundled/docs/where-values-come-from.md +1 -1
  29. package/bundled/mkdocs/404.jinja +6 -0
  30. package/bundled/ssqch.d.ts +78 -18
  31. package/lib/assets.js +11 -12
  32. package/lib/{chunk-3HHRKG33.js → chunk-2L3HR67O.js} +71 -19
  33. package/lib/{chunk-LCPSKHAV.js → chunk-2QTJTEBV.js} +1 -1
  34. package/lib/{chunk-RVBNVGZV.js → chunk-3HZZY3Y7.js} +5 -6
  35. package/lib/{chunk-RKFZSVNF.js → chunk-3K237XAX.js} +10 -11
  36. package/lib/{chunk-HXCLCXRT.js → chunk-443ZQLVX.js} +5 -3
  37. package/lib/{chunk-Q4LFTYK2.js → chunk-5ELAUHRL.js} +20 -20
  38. package/lib/{chunk-SA5KSJ4Y.js → chunk-A75EVUJX.js} +10 -12
  39. package/lib/{chunk-BGCBSQ4A.js → chunk-AIMEXBTK.js} +163 -29
  40. package/lib/{chunk-Y2ESFAAD.js → chunk-B5E27PLU.js} +10 -41
  41. package/lib/{chunk-RJFWTW2Y.js → chunk-CMJ7X5WW.js} +3 -3
  42. package/lib/{chunk-NKXEPHRZ.js → chunk-ERAIEV3O.js} +106 -4
  43. package/lib/{chunk-E5UB2YY7.js → chunk-FCM3NYFR.js} +11 -9
  44. package/lib/{chunk-3EPHKJEG.js → chunk-GJNIQAIH.js} +8 -8
  45. package/lib/{chunk-CB6YFUXU.js → chunk-GLJQ4C76.js} +40 -21
  46. package/lib/{chunk-DDV6JEC2.js → chunk-GS5B3CBW.js} +1 -1
  47. package/lib/chunk-H5K2ZE7B.js +219 -0
  48. package/lib/{chunk-NFJJKDRI.js → chunk-HFSWUTXX.js} +1 -1
  49. package/lib/{chunk-4Q6WMTER.js → chunk-HWW5NCVJ.js} +1 -1
  50. package/lib/{chunk-LAV3DEY4.js → chunk-I3HYKEEW.js} +1 -1
  51. package/lib/{chunk-JWCCVTTR.js → chunk-IOBC665M.js} +2 -4
  52. package/lib/chunk-JC54PHIT.js +7992 -0
  53. package/lib/{chunk-2LEOPLTZ.js → chunk-KCF2Z6N7.js} +3 -5
  54. package/lib/{chunk-DMVJ53SM.js → chunk-KZZS4W2V.js} +15 -15
  55. package/lib/{chunk-RM5Q3KFB.js → chunk-LJOURBYT.js} +14 -13
  56. package/lib/chunk-OQGXZYZS.js +45 -0
  57. package/lib/chunk-OSBEH67S.js +6296 -0
  58. package/lib/{chunk-DW7VMJEZ.js → chunk-QJ5ZFTML.js} +14 -13
  59. package/lib/{chunk-NUUEOGLZ.js → chunk-QLUTNR37.js} +11 -11
  60. package/lib/{chunk-HGJ5VWUR.js → chunk-RBNPBTDP.js} +1 -1
  61. package/lib/{chunk-F65YUXZ7.js → chunk-RIAOXEXC.js} +10 -4
  62. package/lib/chunk-RVXGUMFI.js +21 -0
  63. package/lib/{chunk-N4O5MDIB.js → chunk-RYIWYWRQ.js} +5 -7
  64. package/lib/{chunk-EEJDLCD3.js → chunk-RZYAIX2R.js} +12 -11
  65. package/lib/{chunk-7HXCQEGA.js → chunk-V2FSMOFX.js} +3 -3
  66. package/lib/{chunk-HDQ4SRWM.js → chunk-X2GAVYV2.js} +525 -75
  67. package/lib/chunk-XS4EJSEK.js +279 -0
  68. package/lib/chunk-YCOTX2VM.js +37 -0
  69. package/lib/{chunk-QMA7CK7B.js → chunk-Z44IAMNG.js} +137 -32
  70. package/lib/chunk-Z5OP43HU.js +2945 -0
  71. package/lib/{chunk-JXZT5L7W.js → chunk-ZINLHOX4.js} +2 -3
  72. package/lib/{chunk-SRNLKWXL.js → chunk-ZR3JYLFB.js} +893 -12382
  73. package/lib/cli.js +82 -41
  74. package/lib/elements.js +11 -12
  75. package/lib/image.js +11 -11
  76. package/lib/links.js +11 -12
  77. package/lib/minify.js +71 -13
  78. package/lib/redirects.js +11 -12
  79. package/lib/rss.js +13 -11
  80. package/lib/sass.js +13 -245
  81. package/lib/sitemap.js +19 -18
  82. package/lib/ssqch.js +6 -5
  83. package/package.json +1 -1
  84. package/types/index.d.ts +59 -13
  85. package/types/minify.d.ts +15 -3
  86. package/types/sass.d.ts +2 -0
  87. package/types/sitemap.d.ts +2 -2
  88. package/wasm/markdown.wasm +0 -0
  89. package/wasm/minify.wasm +0 -0
  90. package/wasm/sass.wasm +0 -0
  91. package/lib/chunk-5DNDSNTP.js +0 -1541
  92. package/lib/chunk-VJWQSYEG.js +0 -119
  93. package/lib/chunk-ZM6TU2JB.js +0 -1287
  94. /package/lib/{chunk-BGCBSQ4A.js.LEGAL.txt → chunk-AIMEXBTK.js.LEGAL.txt} +0 -0
  95. /package/lib/{chunk-SRNLKWXL.js.LEGAL.txt → chunk-ZR3JYLFB.js.LEGAL.txt} +0 -0
@@ -37,8 +37,11 @@ _ssqch() {
37
37
  ssqch,help)
38
38
  cmd="ssqch__subcmd__help"
39
39
  ;;
40
- ssqch,import)
41
- cmd="ssqch__subcmd__import"
40
+ ssqch,baseline)
41
+ cmd="ssqch__subcmd__baseline"
42
+ ;;
43
+ ssqch,scout)
44
+ cmd="ssqch__subcmd__scout"
42
45
  ;;
43
46
  ssqch,init)
44
47
  cmd="ssqch__subcmd__init"
@@ -76,8 +79,11 @@ _ssqch() {
76
79
  ssqch__subcmd__help,help)
77
80
  cmd="ssqch__subcmd__help__subcmd__help"
78
81
  ;;
79
- ssqch__subcmd__help,import)
80
- cmd="ssqch__subcmd__help__subcmd__import"
82
+ ssqch__subcmd__help,baseline)
83
+ cmd="ssqch__subcmd__help__subcmd__baseline"
84
+ ;;
85
+ ssqch__subcmd__help,scout)
86
+ cmd="ssqch__subcmd__help__subcmd__scout"
81
87
  ;;
82
88
  ssqch__subcmd__help,init)
83
89
  cmd="ssqch__subcmd__help__subcmd__init"
@@ -101,7 +107,7 @@ _ssqch() {
101
107
 
102
108
  case "${cmd}" in
103
109
  ssqch)
104
- opts="-o -q -v -h -V --root --output --base --offline --env --quiet --verbose --help --version build serve new inspect completions diff footprint init types import capabilities docs help"
110
+ opts="-o -q -v -h -V --root --output --base --offline --env --quiet --verbose --help --version build serve new inspect completions diff footprint init types baseline scout capabilities docs help"
105
111
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 1 ]] ; then
106
112
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
107
113
  return 0
@@ -135,7 +141,7 @@ _ssqch() {
135
141
  return 0
136
142
  ;;
137
143
  ssqch__subcmd__build)
138
- opts="-o -q -v -h --format --root --output --base --offline --env --quiet --verbose --help"
144
+ opts="-o -q -v -h --format --profile --root --output --base --offline --env --quiet --verbose --help"
139
145
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
140
146
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
141
147
  return 0
@@ -245,7 +251,7 @@ _ssqch() {
245
251
  return 0
246
252
  ;;
247
253
  ssqch__subcmd__diff)
248
- opts="-o -q -v -h --exact --ignore --only --lines --format --root --output --base --offline --env --quiet --verbose --help"
254
+ opts="-o -q -v -h --exact --ungrouped --ignore --only --exclude --lines --format --root --output --base --offline --env --quiet --verbose --help"
249
255
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
250
256
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
251
257
  return 0
@@ -259,6 +265,10 @@ _ssqch() {
259
265
  COMPREPLY=($(compgen -f "${cur}"))
260
266
  return 0
261
267
  ;;
268
+ --exclude)
269
+ COMPREPLY=($(compgen -f "${cur}"))
270
+ return 0
271
+ ;;
262
272
  --lines)
263
273
  COMPREPLY=($(compgen -f "${cur}"))
264
274
  return 0
@@ -379,7 +389,7 @@ _ssqch() {
379
389
  return 0
380
390
  ;;
381
391
  ssqch__subcmd__help)
382
- opts="build serve new inspect completions diff footprint init types import capabilities docs help"
392
+ opts="build serve new inspect completions diff footprint init types baseline scout capabilities docs help"
383
393
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
384
394
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
385
395
  return 0
@@ -490,7 +500,21 @@ _ssqch() {
490
500
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
491
501
  return 0
492
502
  ;;
493
- ssqch__subcmd__help__subcmd__import)
503
+ ssqch__subcmd__help__subcmd__baseline)
504
+ opts=""
505
+ if [[ ${cur} == -* || ${COMP_CWORD} -eq 3 ]] ; then
506
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
507
+ return 0
508
+ fi
509
+ case "${prev}" in
510
+ *)
511
+ COMPREPLY=()
512
+ ;;
513
+ esac
514
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
515
+ return 0
516
+ ;;
517
+ ssqch__subcmd__help__subcmd__scout)
494
518
  opts=""
495
519
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 3 ]] ; then
496
520
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
@@ -574,33 +598,55 @@ _ssqch() {
574
598
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
575
599
  return 0
576
600
  ;;
577
- ssqch__subcmd__import)
578
- opts="-o -q -v -h --write --root --output --base --offline --env --quiet --verbose --help"
601
+ ssqch__subcmd__baseline)
602
+ opts="-q -h --from --runs --commit --to --link --patch --copy-installs --root --quiet --help"
579
603
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
580
604
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
581
605
  return 0
582
606
  fi
583
607
  case "${prev}" in
584
- --root)
608
+ --from)
585
609
  COMPREPLY=($(compgen -f "${cur}"))
586
610
  return 0
587
611
  ;;
588
- --output)
612
+ --runs)
589
613
  COMPREPLY=($(compgen -f "${cur}"))
590
614
  return 0
591
615
  ;;
592
- -o)
616
+ --commit)
593
617
  COMPREPLY=($(compgen -f "${cur}"))
594
618
  return 0
595
619
  ;;
596
- --base)
620
+ --to)
597
621
  COMPREPLY=($(compgen -f "${cur}"))
598
622
  return 0
599
623
  ;;
600
- --env)
624
+ --link)
625
+ COMPREPLY=($(compgen -f "${cur}"))
626
+ return 0
627
+ ;;
628
+ --patch)
601
629
  COMPREPLY=($(compgen -f "${cur}"))
602
630
  return 0
603
631
  ;;
632
+ --root)
633
+ COMPREPLY=($(compgen -f "${cur}"))
634
+ return 0
635
+ ;;
636
+ *)
637
+ COMPREPLY=()
638
+ ;;
639
+ esac
640
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
641
+ return 0
642
+ ;;
643
+ ssqch__subcmd__scout)
644
+ opts="-h --write-draft --from --format --patch --compare --reference --help"
645
+ if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
646
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
647
+ return 0
648
+ fi
649
+ case "${prev}" in
604
650
  *)
605
651
  COMPREPLY=()
606
652
  ;;
@@ -41,7 +41,8 @@ set edit:completion:arg-completer[ssqch] = {|@words|
41
41
  cand footprint 'Show how much a build weighs: its files by kind, and the heaviest pages and files'
42
42
  cand init 'Create a starter site (config, layout, five posts, data and editor types)'
43
43
  cand types 'Write ssqch.d.ts, the types editors use for ssqch.config.js'
44
- cand import 'Move a site from another generator: rename and rewrite what''s mechanical, and list the rest'
44
+ cand baseline 'Build the site with its old generator in fresh copies and compare the builds'
45
+ cand scout 'Scout a site built with another generator: what moving it to ssqch takes, and what remains during a move'
45
46
  cand capabilities 'Say what this binary supports: template languages, modules, config options and optional features'
46
47
  cand docs 'Read the documentation for this version: a command, config option, function or topic'
47
48
  cand help 'Print this message or the help of the given subcommand(s)'
@@ -54,6 +55,7 @@ set edit:completion:arg-completer[ssqch] = {|@words|
54
55
  cand --base 'Serve the site under a path, like /repo/ (overrides the config''s `base`)'
55
56
  cand --env 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)'
56
57
  cand --offline 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved'
58
+ cand --profile 'Also time every page, template, layout, engine, filter, transform, data file, collection and hook, and list the slowest'
57
59
  cand -q 'Print only warnings and errors'
58
60
  cand --quiet 'Print only warnings and errors'
59
61
  cand -v 'Also list the slowest images to encode'
@@ -131,6 +133,8 @@ set edit:completion:arg-completer[ssqch] = {|@words|
131
133
  &'ssqch;diff'= {
132
134
  cand --ignore 'Leave out text matching this regular expression before comparing (repeatable)'
133
135
  cand --only 'Only compare files matching this glob, like ''**/*.html'' (repeatable)'
136
+ cand --exclude 'Leave out files matching this glob, like ''img/**'' (repeatable)'
137
+ cand --ungrouped 'List each file with all its changes, without grouping the ones shared by several files'
134
138
  cand --lines 'Changed lines to show for each file (0 for all)'
135
139
  cand --format 'text or json'
136
140
  cand --root 'Project root (defaults to the current directory)'
@@ -194,18 +198,27 @@ set edit:completion:arg-completer[ssqch] = {|@words|
194
198
  cand -h 'Print help'
195
199
  cand --help 'Print help'
196
200
  }
197
- &'ssqch;import'= {
201
+ &'ssqch;baseline'= {
198
202
  cand --root 'Project root (defaults to the current directory)'
199
- cand -o 'Override the output directory (relative to the root)'
200
- cand --output 'Override the output directory (relative to the root)'
201
- cand --base 'Serve the site under a path, like /repo/ (overrides the config''s `base`)'
202
- cand --env 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)'
203
- cand --write 'Make the changes (without it, only list them)'
204
- cand --offline 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved'
203
+ cand --from 'The folder the command writes (default _site)'
204
+ cand --runs 'How many builds to make and compare (default 3)'
205
+ cand --commit 'Build this commit instead of the working tree'
206
+ cand --to 'What to call the builds (default ref)'
207
+ cand --link 'Link this folder of the site into each copy (repeatable)'
208
+ cand --patch 'Apply this patch to each copy before building'
209
+ cand --copy-installs 'Copy the installs into each copy instead of linking them'
205
210
  cand -q 'Print only warnings and errors'
206
211
  cand --quiet 'Print only warnings and errors'
207
- cand -v 'Also list the slowest images to encode'
208
- cand --verbose 'Also list the slowest images to encode'
212
+ cand -h 'Print help'
213
+ cand --help 'Print help'
214
+ }
215
+ &'ssqch;scout'= {
216
+ cand --from 'The generator the site is built with, when scout finds another'
217
+ cand --format 'text or json'
218
+ cand --write-draft 'Write the new files of the draft; never overwrites a file'
219
+ cand --patch 'Write the mechanical edits to FILE as a patch to review; nothing is applied'
220
+ cand --compare 'Also build with ssqch and compare with the reference build'
221
+ cand --reference 'The reference build to compare with'
209
222
  cand -h 'Print help'
210
223
  cand --help 'Print help'
211
224
  }
@@ -250,7 +263,8 @@ set edit:completion:arg-completer[ssqch] = {|@words|
250
263
  cand footprint 'Show how much a build weighs: its files by kind, and the heaviest pages and files'
251
264
  cand init 'Create a starter site (config, layout, five posts, data and editor types)'
252
265
  cand types 'Write ssqch.d.ts, the types editors use for ssqch.config.js'
253
- cand import 'Move a site from another generator: rename and rewrite what''s mechanical, and list the rest'
266
+ cand baseline 'Build the site with its old generator in fresh copies and compare the builds'
267
+ cand scout 'Scout a site built with another generator: what moving it to ssqch takes, and what remains during a move'
254
268
  cand capabilities 'Say what this binary supports: template languages, modules, config options and optional features'
255
269
  cand docs 'Read the documentation for this version: a command, config option, function or topic'
256
270
  cand help 'Print this message or the help of the given subcommand(s)'
@@ -273,7 +287,9 @@ set edit:completion:arg-completer[ssqch] = {|@words|
273
287
  }
274
288
  &'ssqch;help;types'= {
275
289
  }
276
- &'ssqch;help;import'= {
290
+ &'ssqch;help;baseline'= {
291
+ }
292
+ &'ssqch;help;scout'= {
277
293
  }
278
294
  &'ssqch;help;capabilities'= {
279
295
  }
@@ -42,7 +42,8 @@ complete -c ssqch -n "__fish_ssqch_needs_command" -f -a "diff" -d 'Compare two b
42
42
  complete -c ssqch -n "__fish_ssqch_needs_command" -f -a "footprint" -d 'Show how much a build weighs: its files by kind, and the heaviest pages and files'
43
43
  complete -c ssqch -n "__fish_ssqch_needs_command" -f -a "init" -d 'Create a starter site (config, layout, five posts, data and editor types)'
44
44
  complete -c ssqch -n "__fish_ssqch_needs_command" -f -a "types" -d 'Write ssqch.d.ts, the types editors use for ssqch.config.js'
45
- complete -c ssqch -n "__fish_ssqch_needs_command" -f -a "import" -d 'Move a site from another generator: rename and rewrite what\'s mechanical, and list the rest'
45
+ complete -c ssqch -n "__fish_ssqch_needs_command" -f -a "baseline" -d 'Build the site with its old generator in fresh copies and compare the builds'
46
+ complete -c ssqch -n "__fish_ssqch_needs_command" -f -a "scout" -d 'Scout a site built with another generator: what moving it to ssqch takes, and what remains during a move'
46
47
  complete -c ssqch -n "__fish_ssqch_needs_command" -f -a "capabilities" -d 'Say what this binary supports: template languages, modules, config options and optional features'
47
48
  complete -c ssqch -n "__fish_ssqch_needs_command" -f -a "docs" -d 'Read the documentation for this version: a command, config option, function or topic'
48
49
  complete -c ssqch -n "__fish_ssqch_needs_command" -f -a "help" -d 'Print this message or the help of the given subcommand(s)'
@@ -52,6 +53,7 @@ complete -c ssqch -n "__fish_ssqch_using_subcommand build" -s o -l output -d 'Ov
52
53
  complete -c ssqch -n "__fish_ssqch_using_subcommand build" -l base -d 'Serve the site under a path, like /repo/ (overrides the config\'s `base`)' -r
53
54
  complete -c ssqch -n "__fish_ssqch_using_subcommand build" -l env -d 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)' -r
54
55
  complete -c ssqch -n "__fish_ssqch_using_subcommand build" -l offline -d 'Don\'t use the network: `fetch()` answers from the copies its `cache` option saved'
56
+ complete -c ssqch -n "__fish_ssqch_using_subcommand build" -l profile -d 'Also time every page, template, layout, engine, filter, transform, data file, collection and hook, and list the slowest'
55
57
  complete -c ssqch -n "__fish_ssqch_using_subcommand build" -s q -l quiet -d 'Print only warnings and errors'
56
58
  complete -c ssqch -n "__fish_ssqch_using_subcommand build" -s v -l verbose -d 'Also list the slowest images to encode'
57
59
  complete -c ssqch -n "__fish_ssqch_using_subcommand build" -s h -l help -d 'Print help'
@@ -99,6 +101,8 @@ complete -c ssqch -n "__fish_ssqch_using_subcommand completions" -s v -l verbose
99
101
  complete -c ssqch -n "__fish_ssqch_using_subcommand completions" -s h -l help -d 'Print help'
100
102
  complete -c ssqch -n "__fish_ssqch_using_subcommand diff" -l ignore -d 'Leave out text matching this regular expression before comparing (repeatable)' -r
101
103
  complete -c ssqch -n "__fish_ssqch_using_subcommand diff" -l only -d 'Only compare files matching this glob, like \'**/*.html\' (repeatable)' -r
104
+ complete -c ssqch -n "__fish_ssqch_using_subcommand diff" -l exclude -d 'Leave out files matching this glob, like \'img/**\' (repeatable)' -r
105
+ complete -c ssqch -n "__fish_ssqch_using_subcommand diff" -l ungrouped -d 'List each file with all its changes, without grouping the ones shared by several files'
102
106
  complete -c ssqch -n "__fish_ssqch_using_subcommand diff" -l lines -d 'Changed lines to show for each file (0 for all)' -r
103
107
  complete -c ssqch -n "__fish_ssqch_using_subcommand diff" -l format -d 'text or json' -r
104
108
  complete -c ssqch -n "__fish_ssqch_using_subcommand diff" -l root -d 'Project root (defaults to the current directory)' -r -F
@@ -139,15 +143,23 @@ complete -c ssqch -n "__fish_ssqch_using_subcommand types" -l offline -d 'Don\'t
139
143
  complete -c ssqch -n "__fish_ssqch_using_subcommand types" -s q -l quiet -d 'Print only warnings and errors'
140
144
  complete -c ssqch -n "__fish_ssqch_using_subcommand types" -s v -l verbose -d 'Also list the slowest images to encode'
141
145
  complete -c ssqch -n "__fish_ssqch_using_subcommand types" -s h -l help -d 'Print help'
142
- complete -c ssqch -n "__fish_ssqch_using_subcommand import" -l root -d 'Project root (defaults to the current directory)' -r -F
143
- complete -c ssqch -n "__fish_ssqch_using_subcommand import" -s o -l output -d 'Override the output directory (relative to the root)' -r -F
144
- complete -c ssqch -n "__fish_ssqch_using_subcommand import" -l base -d 'Serve the site under a path, like /repo/ (overrides the config\'s `base`)' -r
145
- complete -c ssqch -n "__fish_ssqch_using_subcommand import" -l env -d 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)' -r
146
- complete -c ssqch -n "__fish_ssqch_using_subcommand import" -l write -d 'Make the changes (without it, only list them)'
147
- complete -c ssqch -n "__fish_ssqch_using_subcommand import" -l offline -d 'Don\'t use the network: `fetch()` answers from the copies its `cache` option saved'
148
- complete -c ssqch -n "__fish_ssqch_using_subcommand import" -s q -l quiet -d 'Print only warnings and errors'
149
- complete -c ssqch -n "__fish_ssqch_using_subcommand import" -s v -l verbose -d 'Also list the slowest images to encode'
150
- complete -c ssqch -n "__fish_ssqch_using_subcommand import" -s h -l help -d 'Print help'
146
+ complete -c ssqch -n "__fish_ssqch_using_subcommand baseline" -l root -d 'Project root (defaults to the current directory)' -r -F
147
+ complete -c ssqch -n "__fish_ssqch_using_subcommand baseline" -l from -d 'The folder the command writes (default _site)' -r
148
+ complete -c ssqch -n "__fish_ssqch_using_subcommand baseline" -l runs -d 'How many builds to make and compare (default 3)' -r
149
+ complete -c ssqch -n "__fish_ssqch_using_subcommand baseline" -l commit -d 'Build this commit instead of the working tree' -r
150
+ complete -c ssqch -n "__fish_ssqch_using_subcommand baseline" -l to -d 'What to call the builds (default ref)' -r
151
+ complete -c ssqch -n "__fish_ssqch_using_subcommand baseline" -l link -d 'Link this folder of the site into each copy (repeatable)' -r -F
152
+ complete -c ssqch -n "__fish_ssqch_using_subcommand baseline" -l patch -d 'Apply this patch to each copy before building' -r -F
153
+ complete -c ssqch -n "__fish_ssqch_using_subcommand baseline" -l copy-installs -d 'Copy the installs into each copy instead of linking them'
154
+ complete -c ssqch -n "__fish_ssqch_using_subcommand baseline" -s q -l quiet -d 'Print only warnings and errors'
155
+ complete -c ssqch -n "__fish_ssqch_using_subcommand baseline" -s h -l help -d 'Print help'
156
+ complete -c ssqch -n "__fish_ssqch_using_subcommand scout" -l from -d 'The generator the site is built with, when scout finds another' -r
157
+ complete -c ssqch -n "__fish_ssqch_using_subcommand scout" -l format -d 'text or json' -r
158
+ complete -c ssqch -n "__fish_ssqch_using_subcommand scout" -l write-draft -d 'Write the new files of the draft; never overwrites a file'
159
+ complete -c ssqch -n "__fish_ssqch_using_subcommand scout" -l patch -d 'Write the mechanical edits to FILE as a patch to review; nothing is applied' -r -F
160
+ complete -c ssqch -n "__fish_ssqch_using_subcommand scout" -l compare -d 'Also build with ssqch and compare with the reference build'
161
+ complete -c ssqch -n "__fish_ssqch_using_subcommand scout" -l reference -d 'The reference build to compare with' -r -F
162
+ complete -c ssqch -n "__fish_ssqch_using_subcommand scout" -s h -l help -d 'Print help'
151
163
  complete -c ssqch -n "__fish_ssqch_using_subcommand capabilities" -l format -d 'text or json' -r
152
164
  complete -c ssqch -n "__fish_ssqch_using_subcommand capabilities" -l root -d 'Project root (defaults to the current directory)' -r -F
153
165
  complete -c ssqch -n "__fish_ssqch_using_subcommand capabilities" -s o -l output -d 'Override the output directory (relative to the root)' -r -F
@@ -167,16 +179,17 @@ complete -c ssqch -n "__fish_ssqch_using_subcommand docs" -l offline -d 'Don\'t
167
179
  complete -c ssqch -n "__fish_ssqch_using_subcommand docs" -s q -l quiet -d 'Print only warnings and errors'
168
180
  complete -c ssqch -n "__fish_ssqch_using_subcommand docs" -s v -l verbose -d 'Also list the slowest images to encode'
169
181
  complete -c ssqch -n "__fish_ssqch_using_subcommand docs" -s h -l help -d 'Print help'
170
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "build" -d 'Build the site (default)'
171
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "serve" -d 'Build, serve, watch for changes and live-reload the browser'
172
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "new" -d 'Create a page from a blueprint (a file in _blueprints/), with its title and date filled in'
173
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "inspect" -d 'Show where a page comes from, and which level of the data cascade set each value'
174
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "completions" -d 'Print a completion script for your shell, so Tab finishes commands and options'
175
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "diff" -d 'Compare two builds of a site: URLs added and removed, and what changed on each page'
176
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "footprint" -d 'Show how much a build weighs: its files by kind, and the heaviest pages and files'
177
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "init" -d 'Create a starter site (config, layout, five posts, data and editor types)'
178
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "types" -d 'Write ssqch.d.ts, the types editors use for ssqch.config.js'
179
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "import" -d 'Move a site from another generator: rename and rewrite what\'s mechanical, and list the rest'
180
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "capabilities" -d 'Say what this binary supports: template languages, modules, config options and optional features'
181
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "docs" -d 'Read the documentation for this version: a command, config option, function or topic'
182
- complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types import capabilities docs help" -f -a "help" -d 'Print this message or the help of the given subcommand(s)'
182
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "build" -d 'Build the site (default)'
183
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "serve" -d 'Build, serve, watch for changes and live-reload the browser'
184
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "new" -d 'Create a page from a blueprint (a file in _blueprints/), with its title and date filled in'
185
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "inspect" -d 'Show where a page comes from, and which level of the data cascade set each value'
186
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "completions" -d 'Print a completion script for your shell, so Tab finishes commands and options'
187
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "diff" -d 'Compare two builds of a site: URLs added and removed, and what changed on each page'
188
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "footprint" -d 'Show how much a build weighs: its files by kind, and the heaviest pages and files'
189
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "init" -d 'Create a starter site (config, layout, five posts, data and editor types)'
190
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "types" -d 'Write ssqch.d.ts, the types editors use for ssqch.config.js'
191
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "baseline" -d 'Build the site with its old generator in fresh copies and compare the builds'
192
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "scout" -d 'Scout a site built with another generator: what moving it to ssqch takes, and what remains during a move'
193
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "capabilities" -d 'Say what this binary supports: template languages, modules, config options and optional features'
194
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "docs" -d 'Read the documentation for this version: a command, config option, function or topic'
195
+ complete -c ssqch -n "__fish_ssqch_using_subcommand help; and not __fish_seen_subcommand_from build serve new inspect completions diff footprint init types baseline scout capabilities docs help" -f -a "help" -d 'Print this message or the help of the given subcommand(s)'
@@ -44,7 +44,8 @@ Register-ArgumentCompleter -Native -CommandName 'ssqch' -ScriptBlock {
44
44
  [CompletionResult]::new('footprint', 'footprint', [CompletionResultType]::ParameterValue, 'Show how much a build weighs: its files by kind, and the heaviest pages and files')
45
45
  [CompletionResult]::new('init', 'init', [CompletionResultType]::ParameterValue, 'Create a starter site (config, layout, five posts, data and editor types)')
46
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')
47
+ [CompletionResult]::new('baseline', 'baseline', [CompletionResultType]::ParameterValue, 'Build the site with its old generator in fresh copies and compare the builds')
48
+ [CompletionResult]::new('scout', 'scout', [CompletionResultType]::ParameterValue, 'Scout a site built with another generator: what moving it to ssqch takes, and what remains during a move')
48
49
  [CompletionResult]::new('capabilities', 'capabilities', [CompletionResultType]::ParameterValue, 'Say what this binary supports: template languages, modules, config options and optional features')
49
50
  [CompletionResult]::new('docs', 'docs', [CompletionResultType]::ParameterValue, 'Read the documentation for this version: a command, config option, function or topic')
50
51
  [CompletionResult]::new('help', 'help', [CompletionResultType]::ParameterValue, 'Print this message or the help of the given subcommand(s)')
@@ -58,6 +59,7 @@ Register-ArgumentCompleter -Native -CommandName 'ssqch' -ScriptBlock {
58
59
  [CompletionResult]::new('--base', '--base', [CompletionResultType]::ParameterName, 'Serve the site under a path, like /repo/ (overrides the config''s `base`)')
59
60
  [CompletionResult]::new('--env', '--env', [CompletionResultType]::ParameterName, 'development or production (default: $SSQCH_ENV, $NODE_ENV, then production for `build` and development for `serve`)')
60
61
  [CompletionResult]::new('--offline', '--offline', [CompletionResultType]::ParameterName, 'Don''t use the network: `fetch()` answers from the copies its `cache` option saved')
62
+ [CompletionResult]::new('--profile', '--profile', [CompletionResultType]::ParameterName, 'Also time every page, template, layout, engine, filter, transform, data file, collection and hook, and list the slowest')
61
63
  [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
62
64
  [CompletionResult]::new('--quiet', '--quiet', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
63
65
  [CompletionResult]::new('-v', '-v', [CompletionResultType]::ParameterName, 'Also list the slowest images to encode')
@@ -140,6 +142,8 @@ Register-ArgumentCompleter -Native -CommandName 'ssqch' -ScriptBlock {
140
142
  'ssqch;diff' {
141
143
  [CompletionResult]::new('--ignore', '--ignore', [CompletionResultType]::ParameterName, 'Leave out text matching this regular expression before comparing (repeatable)')
142
144
  [CompletionResult]::new('--only', '--only', [CompletionResultType]::ParameterName, 'Only compare files matching this glob, like ''**/*.html'' (repeatable)')
145
+ [CompletionResult]::new('--exclude', '--exclude', [CompletionResultType]::ParameterName, 'Leave out files matching this glob, like ''img/**'' (repeatable)')
146
+ [CompletionResult]::new('--ungrouped', '--ungrouped', [CompletionResultType]::ParameterName, 'List each file with all its changes, without grouping the ones shared by several files')
143
147
  [CompletionResult]::new('--lines', '--lines', [CompletionResultType]::ParameterName, 'Changed lines to show for each file (0 for all)')
144
148
  [CompletionResult]::new('--format', '--format', [CompletionResultType]::ParameterName, 'text or json')
145
149
  [CompletionResult]::new('--root', '--root', [CompletionResultType]::ParameterName, 'Project root (defaults to the current directory)')
@@ -207,18 +211,28 @@ Register-ArgumentCompleter -Native -CommandName 'ssqch' -ScriptBlock {
207
211
  [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
208
212
  break
209
213
  }
210
- 'ssqch;import' {
214
+ 'ssqch;baseline' {
211
215
  [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')
216
+ [CompletionResult]::new('--from', '--from', [CompletionResultType]::ParameterName, 'The folder the command writes (default _site)')
217
+ [CompletionResult]::new('--runs', '--runs', [CompletionResultType]::ParameterName, 'How many builds to make and compare (default 3)')
218
+ [CompletionResult]::new('--commit', '--commit', [CompletionResultType]::ParameterName, 'Build this commit instead of the working tree')
219
+ [CompletionResult]::new('--to', '--to', [CompletionResultType]::ParameterName, 'What to call the builds (default ref)')
220
+ [CompletionResult]::new('--link', '--link', [CompletionResultType]::ParameterName, 'Link this folder of the site into each copy (repeatable)')
221
+ [CompletionResult]::new('--patch', '--patch', [CompletionResultType]::ParameterName, 'Apply this patch to each copy before building')
222
+ [CompletionResult]::new('--copy-installs', '--copy-installs', [CompletionResultType]::ParameterName, 'Copy the installs into each copy instead of linking them')
218
223
  [CompletionResult]::new('-q', '-q', [CompletionResultType]::ParameterName, 'Print only warnings and errors')
219
224
  [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')
225
+ [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
226
+ [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
227
+ break
228
+ }
229
+ 'ssqch;scout' {
230
+ [CompletionResult]::new('--from', '--from', [CompletionResultType]::ParameterName, 'The generator the site is built with, when scout finds another')
231
+ [CompletionResult]::new('--format', '--format', [CompletionResultType]::ParameterName, 'text or json')
232
+ [CompletionResult]::new('--write-draft', '--write-draft', [CompletionResultType]::ParameterName, 'Write the new files of the draft; never overwrites a file')
233
+ [CompletionResult]::new('--patch', '--patch', [CompletionResultType]::ParameterName, 'Write the mechanical edits to FILE as a patch to review; nothing is applied')
234
+ [CompletionResult]::new('--compare', '--compare', [CompletionResultType]::ParameterName, 'Also build with ssqch and compare with the reference build')
235
+ [CompletionResult]::new('--reference', '--reference', [CompletionResultType]::ParameterName, 'The reference build to compare with')
222
236
  [CompletionResult]::new('-h', '-h', [CompletionResultType]::ParameterName, 'Print help')
223
237
  [CompletionResult]::new('--help', '--help', [CompletionResultType]::ParameterName, 'Print help')
224
238
  break
@@ -266,7 +280,8 @@ Register-ArgumentCompleter -Native -CommandName 'ssqch' -ScriptBlock {
266
280
  [CompletionResult]::new('footprint', 'footprint', [CompletionResultType]::ParameterValue, 'Show how much a build weighs: its files by kind, and the heaviest pages and files')
267
281
  [CompletionResult]::new('init', 'init', [CompletionResultType]::ParameterValue, 'Create a starter site (config, layout, five posts, data and editor types)')
268
282
  [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')
283
+ [CompletionResult]::new('baseline', 'baseline', [CompletionResultType]::ParameterValue, 'Build the site with its old generator in fresh copies and compare the builds')
284
+ [CompletionResult]::new('scout', 'scout', [CompletionResultType]::ParameterValue, 'Scout a site built with another generator: what moving it to ssqch takes, and what remains during a move')
270
285
  [CompletionResult]::new('capabilities', 'capabilities', [CompletionResultType]::ParameterValue, 'Say what this binary supports: template languages, modules, config options and optional features')
271
286
  [CompletionResult]::new('docs', 'docs', [CompletionResultType]::ParameterValue, 'Read the documentation for this version: a command, config option, function or topic')
272
287
  [CompletionResult]::new('help', 'help', [CompletionResultType]::ParameterValue, 'Print this message or the help of the given subcommand(s)')
@@ -299,7 +314,10 @@ Register-ArgumentCompleter -Native -CommandName 'ssqch' -ScriptBlock {
299
314
  'ssqch;help;types' {
300
315
  break
301
316
  }
302
- 'ssqch;help;import' {
317
+ 'ssqch;help;baseline' {
318
+ break
319
+ }
320
+ 'ssqch;help;scout' {
303
321
  break
304
322
  }
305
323
  'ssqch;help;capabilities' {
@@ -47,6 +47,7 @@ _arguments "${_arguments_options[@]}" : \
47
47
  '--base=[Serve the site under a path, like /repo/ (overrides the config'\''s \`base\`)]:BASE:_default' \
48
48
  '--env=[development or production (default\: \$SSQCH_ENV, \$NODE_ENV, then production for \`build\` and development for \`serve\`)]:ENV:_default' \
49
49
  '--offline[Don'\''t use the network\: \`fetch()\` answers from the copies its \`cache\` option saved]' \
50
+ '--profile[Also time every page, template, layout, engine, filter, transform, data file, collection and hook, and list the slowest]' \
50
51
  '-q[Print only warnings and errors]' \
51
52
  '--quiet[Print only warnings and errors]' \
52
53
  '-v[Also list the slowest images to encode]' \
@@ -137,6 +138,8 @@ _arguments "${_arguments_options[@]}" : \
137
138
  _arguments "${_arguments_options[@]}" : \
138
139
  '*--ignore=[Leave out text matching this regular expression before comparing (repeatable)]:REGEX:_default' \
139
140
  '*--only=[Only compare files matching this glob, like '\''**/*.html'\'' (repeatable)]:GLOB:_default' \
141
+ '*--exclude=[Leave out files matching this glob, like '\''img/**'\'' (repeatable)]:GLOB:_default' \
142
+ '--ungrouped[List each file with all its changes, without grouping the ones shared by several files]' \
140
143
  '--lines=[Changed lines to show for each file (0 for all)]:LINES:_default' \
141
144
  '--format=[text or json]:FORMAT:_default' \
142
145
  '--root=[Project root (defaults to the current directory)]:ROOT:_files' \
@@ -211,22 +214,33 @@ _arguments "${_arguments_options[@]}" : \
211
214
  '--help[Print help]' \
212
215
  && ret=0
213
216
  ;;
214
- (import)
217
+ (baseline)
215
218
  _arguments "${_arguments_options[@]}" : \
216
219
  '--root=[Project root (defaults to the current directory)]:ROOT:_files' \
217
- '-o+[Override the output directory (relative to the root)]:OUTPUT:_files' \
218
- '--output=[Override the output directory (relative to the root)]:OUTPUT:_files' \
219
- '--base=[Serve the site under a path, like /repo/ (overrides the config'\''s \`base\`)]:BASE:_default' \
220
- '--env=[development or production (default\: \$SSQCH_ENV, \$NODE_ENV, then production for \`build\` and development for \`serve\`)]:ENV:_default' \
221
- '--write[Make the changes (without it, only list them)]' \
222
- '--offline[Don'\''t use the network\: \`fetch()\` answers from the copies its \`cache\` option saved]' \
220
+ '--from=[The folder the command writes (default _site)]:DIR:_default' \
221
+ '--runs=[How many builds to make and compare (default 3)]:RUNS:_default' \
222
+ '--commit=[Build this commit instead of the working tree]:REV:_default' \
223
+ '--to=[What to call the builds (default ref)]:NAME:_default' \
224
+ '*--link=[Link this folder of the site into each copy (repeatable)]:PATH:_files' \
225
+ '--patch=[Apply this patch to each copy before building]:FILE:_files' \
226
+ '--copy-installs[Copy the installs into each copy instead of linking them]' \
223
227
  '-q[Print only warnings and errors]' \
224
228
  '--quiet[Print only warnings and errors]' \
225
- '-v[Also list the slowest images to encode]' \
226
- '--verbose[Also list the slowest images to encode]' \
227
229
  '-h[Print help]' \
228
230
  '--help[Print help]' \
229
- ':generator -- The generator the site is built with\: eleventy or zola:_default' \
231
+ '*::COMMAND -- The old generator build command:_default' \
232
+ && ret=0
233
+ ;;
234
+ (scout)
235
+ _arguments "${_arguments_options[@]}" : \
236
+ '--from=[The generator the site is built with, when scout finds another]:FROM:_default' \
237
+ '--format=[text or json]:FORMAT:_default' \
238
+ '--write-draft[Write the new files of the draft; never overwrites a file]' \
239
+ '--patch=[Write the mechanical edits to FILE as a patch to review; nothing is applied]:PATCH:_files' \
240
+ '--compare[Also build with ssqch and compare with the reference build]' \
241
+ '--reference=[The reference build to compare with]:REFERENCE:_files' \
242
+ '-h[Print help]' \
243
+ '--help[Print help]' \
230
244
  '::dir -- The site'\''s folder (default\: the current folder):_default' \
231
245
  && ret=0
232
246
  ;;
@@ -314,7 +328,7 @@ _arguments "${_arguments_options[@]}" : \
314
328
  _arguments "${_arguments_options[@]}" : \
315
329
  && ret=0
316
330
  ;;
317
- (import)
331
+ (scout)
318
332
  _arguments "${_arguments_options[@]}" : \
319
333
  && ret=0
320
334
  ;;
@@ -351,7 +365,8 @@ _ssqch_commands() {
351
365
  'footprint:Show how much a build weighs\: its files by kind, and the heaviest pages and files' \
352
366
  'init:Create a starter site (config, layout, five posts, data and editor types)' \
353
367
  'types:Write ssqch.d.ts, the types editors use for ssqch.config.js' \
354
- 'import:Move a site from another generator\: rename and rewrite what'\''s mechanical, and list the rest' \
368
+ 'baseline:Build the site with its old generator in fresh copies and compare the builds' \
369
+ 'scout:Scout a site built with another generator\: what moving it to ssqch takes, and what remains during a move' \
355
370
  'capabilities:Say what this binary supports\: template languages, modules, config options and optional features' \
356
371
  'docs:Read the documentation for this version\: a command, config option, function or topic' \
357
372
  'help:Print this message or the help of the given subcommand(s)' \
@@ -400,7 +415,8 @@ _ssqch__subcmd__help_commands() {
400
415
  'footprint:Show how much a build weighs\: its files by kind, and the heaviest pages and files' \
401
416
  'init:Create a starter site (config, layout, five posts, data and editor types)' \
402
417
  'types:Write ssqch.d.ts, the types editors use for ssqch.config.js' \
403
- 'import:Move a site from another generator\: rename and rewrite what'\''s mechanical, and list the rest' \
418
+ 'baseline:Build the site with its old generator in fresh copies and compare the builds' \
419
+ 'scout:Scout a site built with another generator\: what moving it to ssqch takes, and what remains during a move' \
404
420
  'capabilities:Say what this binary supports\: template languages, modules, config options and optional features' \
405
421
  'docs:Read the documentation for this version\: a command, config option, function or topic' \
406
422
  'help:Print this message or the help of the given subcommand(s)' \
@@ -442,10 +458,10 @@ _ssqch__subcmd__help__subcmd__help_commands() {
442
458
  local commands; commands=()
443
459
  _describe -t commands 'ssqch help help commands' commands "$@"
444
460
  }
445
- (( $+functions[_ssqch__subcmd__help__subcmd__import_commands] )) ||
446
- _ssqch__subcmd__help__subcmd__import_commands() {
461
+ (( $+functions[_ssqch__subcmd__help__subcmd__scout_commands] )) ||
462
+ _ssqch__subcmd__help__subcmd__scout_commands() {
447
463
  local commands; commands=()
448
- _describe -t commands 'ssqch help import commands' commands "$@"
464
+ _describe -t commands 'ssqch help scout commands' commands "$@"
449
465
  }
450
466
  (( $+functions[_ssqch__subcmd__help__subcmd__init_commands] )) ||
451
467
  _ssqch__subcmd__help__subcmd__init_commands() {
@@ -472,10 +488,15 @@ _ssqch__subcmd__help__subcmd__types_commands() {
472
488
  local commands; commands=()
473
489
  _describe -t commands 'ssqch help types commands' commands "$@"
474
490
  }
475
- (( $+functions[_ssqch__subcmd__import_commands] )) ||
476
- _ssqch__subcmd__import_commands() {
491
+ (( $+functions[_ssqch__subcmd__baseline_commands] )) ||
492
+ _ssqch__subcmd__baseline_commands() {
493
+ local commands; commands=()
494
+ _describe -t commands 'ssqch baseline commands' commands "$@"
495
+ }
496
+ (( $+functions[_ssqch__subcmd__scout_commands] )) ||
497
+ _ssqch__subcmd__scout_commands() {
477
498
  local commands; commands=()
478
- _describe -t commands 'ssqch import commands' commands "$@"
499
+ _describe -t commands 'ssqch scout commands' commands "$@"
479
500
  }
480
501
  (( $+functions[_ssqch__subcmd__init_commands] )) ||
481
502
  _ssqch__subcmd__init_commands() {
@@ -37,7 +37,7 @@ ssqch build --format json
37
37
 
38
38
  - **Each warning and error** has a `code` and the `message` a person would have read. `file` (from the project root) is there when the problem is in a file that exists, `line` when the line is known, `field` for a [schema](content-schemas.md) problem, and `url` for a problem in a written page, like a broken link.
39
39
  - **`line` is a line of the file.** Template languages count from the end of the front matter, which is the number in the message (`index.edge:4`); the report adds the front matter back (`"line": 7`).
40
- - **The codes:** `config`, `data`, `front-matter`, `template`, `schema`, `conflict` (two pages write the same file), `links`, `images`, `assets`, `fetch`, `passthrough`, `last-modified`, `hook`, `console` (`console.warn` in a config), `template-formats` (files in a template language the site doesn't list), `other-generator`, `foreign-key` and `foreign-global` (another generator's config, front matter or template data), `over-budget` (a [footprint budget](footprint.md)), `missing-asset` (from `ssqch serve`), and `build` for anything else.
40
+ - **The codes:** `config`, `data`, `front-matter`, `template`, `schema`, `conflict` (two pages write the same file), `links`, `images`, `assets`, `fetch`, `passthrough`, `last-modified`, `hook`, `console` (`console.warn` in a config), `template-formats` (files in a template language the site doesn't list), `other-generator`, `foreign-key` and `foreign-global` (another generator's config, front matter or template data), `over-budget` (a [footprint budget](footprint.md)), `slow-call` (a filter, transform or collection of the site's that took a second or more in one call: [Where the time went](build-summary.md#where-the-time-went)), `missing-asset` (from `ssqch serve`), and `build` for anything else.
41
41
  - **A build that works** also has `durationMs`, `pages` (`written`, `templates`, `bytes`, and `new` and `gone` since the last build to that folder, or `null` when there wasn't one), `copied`, `removed`, `drafts` (the `draft: true` pages a production build left out), `written` (each page's file, from the output folder), `summary` (the lines plugins add to the [build summary](build-summary.md)) and `timings`.
42
42
  - **Standard output is only the report.** The lines a person would have read (`[ssqch] Writing ...`), `console.log` from your config and the output of `beforeBuild` commands go to standard error; `--quiet` leaves the progress lines out.
43
43
 
@@ -68,3 +68,14 @@ ssqch serve --port 0 --ready-file .cache/ready.json &
68
68
  `ok` is whether that first build worked (the server keeps running either way, and rebuilds when a file changes). The file is deleted when the server starts, so one from an earlier run never counts, and it's written again when a changed config loads, since `output` and `base` can change with it.
69
69
 
70
70
  The other commands with JSON are [`ssqch inspect --format json`](where-values-come-from.md) (where a page's data came from) and [`ssqch diff --format json`](comparing-builds.md) (what a change did to the output; it exits with 0, 1 or 2 like `diff`).
71
+
72
+ ## Moving a site with an agent
73
+
74
+ Every move from another generator so far ran the same loop: build the old site, build the new one, compare, fix the biggest group of differences, repeat. It's a loop an agent can run, as long as each step has an answer it can read:
75
+
76
+ 1. **Reference builds you can trust.** `ssqch baseline "<old build command>"` builds the old site with its own generator three times, each in a fresh copy with every file's time pinned and `TZ=UTC`, into `.cache/ssqch/baseline/ref-1` to `-3`, and names what changes by itself (the build's time, ids from `Math.random()`): pin it, or note an `--ignore` pattern for it, before anything else. After the move's first commit, build the commit before it: `--commit <rev>`. When builds vary, run more of them (`--runs 20`): the summary counts how many builds agree on each file and names the one most like the others, and `.cache/ssqch/baseline/ref-common` has each file's most common version, which is the one to compare with. A commit that needs a fix to build at all takes `--patch fix.patch`; a tool that won't follow a link out of its folder (Hugo's `js.Build`) takes `--copy-installs` (a `hugo` command gets it by itself). Watch the first build's warnings: GitHub Pages' placeholder `github.com/pages/...` URLs mean the reference build is wrong on every page.
77
+ 2. **What the move takes.** `ssqch scout` finds the old generator and lists what the site uses that needs doing, each with its file and line and ssqch's way to do it (or "not in ssqch yet"), with the `ssqch baseline` command for step 1; `--format json` has it as data. `--write-draft` writes the config draft and the other new files, and `--patch move.patch` writes the mechanical edits as a patch to read and `git apply`. Run it again at any point to see what's left. `ssqch docs --from <generator>` has that generator's words with ssqch's for each, and its trailhead.
78
+ 3. **A build that works.** Build into an empty folder (files an earlier build left count as differences): `rm -rf dist && TZ=UTC ssqch build --format json`, until `ok` is true. Each error has a `code`, a `file` and a `line`.
79
+ 4. **The biggest group first.** `ssqch diff .cache/ssqch/baseline/ref-1 dist --format json --lines 0` lists the changes on more than one file as `groups`, the most files first. One cause (a filter that formats dates another way, a layout that lost a `<meta>`) is often hundreds of pages, and fixing it shows what's under it. Each change on a page says which heading it's under (`@ under #its-id`, or `at` in the JSON), to find it in the source, and the notes call out what moves a reader: a changed `<title>`, canonical link or redirect, ids that links point at, and a feed's entries. Build and compare again after each fix. What browsers read the same (attribute order, quotes, entities, `<br/>`), fingerprints and image ids don't count, so what's left is a real difference.
80
+ 5. **Done is a decision.** Stop at `No differences`, or when what's left is on purpose: write each one down with why (an `--ignore` pattern with a comment, or a line in the move's notes). `ssqch diff --exact` shows the bytes that still differ, such as a minifier's.
81
+ 6. **Then ssqch's own features,** one at a time (its Markdown, highlighting, minifying, `toc()`), with a diff after each, so every change in the output has one cause.