@rom-weaver/cli 0.14.1 → 0.15.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -47,46 +47,13 @@ Choose the [webapp](#webapp), [self-hosting](#self-hosting), or [CLI](#cli) path
47
47
 
48
48
  ## Webapp
49
49
 
50
- Open the hosted webapp at **[rom-weaver.com/apply](https://rom-weaver.com/apply)**. You do not need to install anything or create an account. Choose **Apply**, add a ROM and one or more patches, review the detected formats and checksums, then run the workflow and save the result. Use **Create** to generate a distributable patch from an original and a modified file. Your files are processed locally and never leave the device. Install it as a PWA from the browser menu to use it offline. New here? [Try the sample workflow](https://rom-weaver.com/apply?bundle=first-weave.zip) with a tiny original homebrew NES ROM and two independent patches that change “HELLO WORLD” to “ROM WEAVER.” For a guided explanation, use [guided Apply](https://rom-weaver.com/apply?guide=apply), [guided Create](https://rom-weaver.com/create?guide=create), or [guided Bundle](https://rom-weaver.com/apply?guide=bundle). To run the webapp on your own host, see the [Self-hosting](#self-hosting) section below or the [full self-hosting guide](./docs/hosting/self-hosting.md).
50
+ Open [rom-weaver.com/apply](https://rom-weaver.com/apply). Add your ROM and patches, then download the result. Files are processed on your device. No install or account is needed.
51
51
 
52
- ## Self-hosting
53
-
54
- For a quick setup, choose static files, Docker Run, or Docker Compose. The [full self-hosting guide](./docs/hosting/self-hosting.md) covers reverse proxies, subpath routing, HTTPS certificates, service-worker scope, and the required COOP/COEP headers.
55
-
56
- Static release files:
52
+ Start with [your first patch](docs/tutorials/first-patch.md) to practise on supplied homebrew files. The [browser guides](docs/README.md#in-the-browser) cover applying, creating, bundling, and testing ROM patches.
57
53
 
58
- ```bash
59
- mkdir -p rom-weaver-webapp
60
- curl --fail --location --proto '=https' --tlsv1.2 \
61
- --output rom-weaver-webapp.tar.gz \
62
- https://github.com/rom-weaver/rom-weaver/releases/latest/download/rom-weaver-webapp.tar.gz
63
- tar --extract --gzip --file rom-weaver-webapp.tar.gz --directory rom-weaver-webapp
64
- ```
65
-
66
- Serve the extracted `rom-weaver-webapp` directory from an HTTPS static host. For a pinned release, replace `latest` in the URL with its tag.
67
-
68
- Docker Run using the published GitHub Container Registry (GHCR) image:
69
-
70
- ```bash
71
- docker run --detach --name rom-weaver-webapp \
72
- --publish 8080:8080 \
73
- ghcr.io/rom-weaver/rom-weaver-webapp:latest
74
- ```
75
-
76
- Docker Compose using the same published GitHub Container Registry (GHCR) image: Download the [Docker Compose template](https://github.com/rom-weaver/rom-weaver/blob/main/docker-compose.yml) into a new directory:
77
-
78
- ```bash
79
- mkdir -p rom-weaver-compose
80
- cd rom-weaver-compose
81
- curl --fail --location --proto '=https' --tlsv1.2 \
82
- --output docker-compose.yml \
83
- https://raw.githubusercontent.com/rom-weaver/rom-weaver/main/docker-compose.yml
84
- docker compose pull
85
- docker compose up --detach
86
- curl --fail --silent --show-error http://localhost:8080/health
87
- ```
54
+ ## Self-hosting
88
55
 
89
- Only Docker with Compose is required. Set `PORT` to change the host port, for example `PORT=3000 docker compose up --detach`. To build the image from source instead, clone the repository and add `--build` to the `docker compose up` command from its checkout; that path is slower and intended for development. For standalone TLS, mount a trusted certificate as described in the guide and set `HTTPS_PORT` instead.
56
+ Use the published Docker image or static release archive. The [self-hosting guide](docs/hosting/self-hosting.md) covers both, including HTTPS, reverse proxies, and subpaths.
90
57
 
91
58
  ## CLI
92
59
 
@@ -108,7 +75,7 @@ npm install --global rom-weaver
108
75
  ```
109
76
 
110
77
 
111
- Homebrew covers macOS arm64/Intel and Linux arm64/x86-64. The install script covers macOS and Linux: it downloads the latest release to `~/.local/bin` and checks its build provenance, refusing to install a binary this repository did not publish. npm is the only channel covering every supported target at once, and needs Node.js 22+.
78
+ Homebrew covers macOS arm64/Intel and Linux arm64/x86-64. The install script covers macOS and Linux: it downloads the latest release to `~/.local/bin` and checks its build provenance, refusing a definite verification failure. If the check cannot run, it warns and continues unless strict verification is enabled; see [Verify a download](docs/how-to/verify-downloads.md). npm is the only channel covering every supported target at once, and needs Node.js 22+.
112
79
 
113
80
  <a name="build-from-source"></a>
114
81
 
@@ -120,19 +87,15 @@ The [development guide](./docs/development/development.md) covers the full toolc
120
87
 
121
88
  ## Why
122
89
 
123
- Every console generation brought its own compressed format: CHD for discs, RVZ for GameCube and Wii, Z3DS for 3DS ROMs, CSO and PBP for PSP, plus the usual ZIP and 7z on top. Working across them can mean finding several separate programs, learning different flags, and checking which builds are available for your platform.
124
-
125
- Patching adds another manual sequence. A translation, bugfix, and undub may need to run in a specific order, with intermediate files kept straight and a compressed input unpacked before the first patch and recompressed afterward. Repeating that setup whenever the patch combination changes adds disk churn and room for mistakes to what should be one workflow.
126
-
127
- The last piece is curation. Keeping a collection in order means storing ROMs compressed, keeping the patches next to them, and being able to prove months later that a patched file came from the ROM you think it did. rom-weaver handles all of it in one place. It reads every format above. It writes CHD, RVZ, Z3DS, ZIP, and 7z archives. It chains as many patches as you want in a single pass without manually unpacking first, and records the whole recipe - patch order, checksums, and output names - in a bundle file you can hand to someone else. Native CLI builds are available for Linux, macOS, and Windows. The browser webapp handles patching and bundle workflows without an install.
90
+ A patch job can require extraction, several patches in order, checksum checks, and compression. rom-weaver runs those steps together and can save the recipe as a bundle.
128
91
 
129
- For the current measurements and trade-offs, see the [performance brief](#performance). For how rom-weaver lines up against the tools you may already use, the [comparison with similar tools](./docs/explanation/comparisons.md) puts it beside RomPatcher.js, Flips, MultiPatch, xdelta3, chdman, and Dolphin tool, format by format and feature by feature.
92
+ [Browser and CLI](docs/explanation/browser-and-cli.md) explains the two interfaces. [Comparison with similar tools](docs/explanation/comparisons.md) covers alternatives.
130
93
 
131
94
  ## Performance
132
95
 
133
- rom-weaver matches or beats the reference tools on every measured axis: extraction time, compression time, and output size. On the measured arm64 corpus, extraction is faster in all four formats. CHD extracts 3.1–5.8× faster, RVZ 1.6–2.0×, ZIP 1.6–2.7×, and 7z 1.0–4.7×. RVZ and ZIP compression are 1.1–1.3× faster. 7z compression is even with its reference. CHD compression ranges from even to 1.3× faster. Output sizes match the references to within a fraction of a percent.
96
+ The [performance guide](docs/development/performance.md) records measured compression and extraction times, output sizes, hardware, and test settings. Results vary by format and input; some compression cases are slower than the reference tool.
134
97
 
135
- The CLI and the threaded WASM webapp share one Rust engine. The browser adds worker, storage, and OPFS costs, so CLI and browser timings are not comparable. The [performance guide](./docs/development/performance.md) records the machine, corpus, settings, reference-tool versions, and repeated runs for each published result. It also lists the commands that reproduce them. Production WASM is optimized with `wasm-opt -O4`. The browser codec matrix is the runtime check for the shipped worker and storage path.
98
+ The CLI and browser share one Rust engine. Browser workers and storage add costs, so native timings do not predict browser performance.
136
99
 
137
100
  ## Features
138
101
 
@@ -145,7 +108,7 @@ The CLI and the threaded WASM webapp share one Rust engine. The browser adds wor
145
108
  - **Local-first and private.** Everything runs on your machine. The webapp is an installable PWA that works offline and never uploads your files.
146
109
  - **One engine, two frontends.** The same Rust core powers the terminal CLI and the threaded WASM webapp. CLI operation commands can emit line-delimited JSON for scripting.
147
110
 
148
- The complete format, codec, and checksum compatibility tables are maintained in the [CLI guide](./docs/reference/formats.md).
111
+ The complete format, codec, and checksum compatibility tables are maintained in [Supported formats](./docs/reference/formats.md).
149
112
 
150
113
  ## Notices
151
114
 
@@ -561,6 +561,27 @@ esac
561
561
  ;;
562
562
  esac
563
563
  ;;
564
+ (setup)
565
+ _arguments "${_arguments_options[@]}" : \
566
+ '--database-dir=[Install into this directory instead of the per-user data directory]:DIR:_files' \
567
+ '(-v --verbose -q --quiet)--log-level=[How much rom-weaver logs to stderr. Separate from the normal output \[default\: off\]]:LOG_LEVEL:(off error warn info debug trace)' \
568
+ '--force[Download the database again even when it is already installed]' \
569
+ '--json[Print one JSON object per line instead of human-readable output]' \
570
+ '(--no-progress)--progress[Show progress even when output is piped to a file or another program]' \
571
+ '(--progress)--no-progress[Hide progress]' \
572
+ '(--log-level -q --quiet)*-v[Log more\: -v for info, -vv for debug, -vvv for trace]' \
573
+ '(--log-level -q --quiet)*--verbose[Log more\: -v for info, -vv for debug, -vvv for trace]' \
574
+ '(--log-level -v --verbose)-q[Log errors only]' \
575
+ '(--log-level -v --verbose)--quiet[Log errors only]' \
576
+ '--dep-trace[Also log trace output from bundled libraries (for bug reports)]' \
577
+ '(--no-color)--color[Keep colors even when output is piped]' \
578
+ '(--color)--no-color[Turn colors off]' \
579
+ '-y[Answer yes to every confirmation instead of asking. Does not choose between candidates]' \
580
+ '--yes[Answer yes to every confirmation instead of asking. Does not choose between candidates]' \
581
+ '-h[Print help (see more with '\''--help'\'')]' \
582
+ '--help[Print help (see more with '\''--help'\'')]' \
583
+ && ret=0
584
+ ;;
564
585
  (ingest)
565
586
  _arguments "${_arguments_options[@]}" : \
566
587
  '-i+[File to sort into ROMs and patches]:INPUT:_files' \
@@ -700,11 +721,12 @@ _arguments "${_arguments_options[@]}" : \
700
721
  _arguments "${_arguments_options[@]}" : \
701
722
  '-i+[ROM to patch. May be an archive, a disc sheet (.cue/.gdi), or a bundle]:PATH:_files' \
702
723
  '--input=[ROM to patch. May be an archive, a disc sheet (.cue/.gdi), or a bundle]:PATH:_files' \
703
- '*-s+[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable)]:SELECT:_default' \
704
- '*--select=[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable)]:SELECT:_default' \
724
+ '*-s+[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable). --patch-select overrides it for the patch it follows]:SELECT:_default' \
725
+ '*--select=[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable). --patch-select overrides it for the patch it follows]:SELECT:_default' \
705
726
  '--target=[For a .cue or .gdi input, which track gets the patch. Matched like --select and must hit exactly one track]:TARGET:_default' \
706
727
  '*--filter=[Consider only files that look like a rom or a patch, judged by extension (repeatable, comma-separable)]:FILTER:(rom patch)' \
707
728
  '*--patch=[Patch to apply. Repeat once per patch; they run in the order given]:PATCHES:_files' \
729
+ '*--patch-select=[Pick which file to use inside the --patch archive before it. Repeatable, one per --patch; falls back to --select]:GLOB:_default' \
708
730
  '-o+[Where to write the patched ROM. Optional when a bundle already names the output]:OUTPUT:_files' \
709
731
  '--output=[Where to write the patched ROM. Optional when a bundle already names the output]:OUTPUT:_files' \
710
732
  '--bundle=[Follow a rom-weaver-bundle.json recipe\: a file path, or an http(s) URL]:BUNDLE:_files' \
@@ -760,11 +782,12 @@ _arguments "${_arguments_options[@]}" : \
760
782
  _arguments "${_arguments_options[@]}" : \
761
783
  '-i+[ROM to patch. May be an archive, a disc sheet (.cue/.gdi), or a bundle]:PATH:_files' \
762
784
  '--input=[ROM to patch. May be an archive, a disc sheet (.cue/.gdi), or a bundle]:PATH:_files' \
763
- '*-s+[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable)]:SELECT:_default' \
764
- '*--select=[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable)]:SELECT:_default' \
785
+ '*-s+[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable). --patch-select overrides it for the patch it follows]:SELECT:_default' \
786
+ '*--select=[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable). --patch-select overrides it for the patch it follows]:SELECT:_default' \
765
787
  '--target=[For a .cue or .gdi input, which track gets the patch. Matched like --select and must hit exactly one track]:TARGET:_default' \
766
788
  '*--filter=[Consider only files that look like a rom or a patch, judged by extension (repeatable, comma-separable)]:FILTER:(rom patch)' \
767
789
  '*--patch=[Patch to apply. Repeat once per patch; they run in the order given]:PATCHES:_files' \
790
+ '*--patch-select=[Pick which file to use inside the --patch archive before it. Repeatable, one per --patch; falls back to --select]:GLOB:_default' \
768
791
  '-o+[Where to write the patched ROM. Optional when a bundle already names the output]:OUTPUT:_files' \
769
792
  '--output=[Where to write the patched ROM. Optional when a bundle already names the output]:OUTPUT:_files' \
770
793
  '--bundle=[Follow a rom-weaver-bundle.json recipe\: a file path, or an http(s) URL]:BUNDLE:_files' \
@@ -820,10 +843,11 @@ _arguments "${_arguments_options[@]}" : \
820
843
  _arguments "${_arguments_options[@]}" : \
821
844
  '-i+[ROM to check the patches against. May be an archive]:PATH:_files' \
822
845
  '--input=[ROM to check the patches against. May be an archive]:PATH:_files' \
823
- '*-s+[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable)]:SELECT:_default' \
824
- '*--select=[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable)]:SELECT:_default' \
846
+ '*-s+[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable). --patch-select overrides it for the patch it follows]:SELECT:_default' \
847
+ '*--select=[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable). --patch-select overrides it for the patch it follows]:SELECT:_default' \
825
848
  '*--filter=[Consider only files that look like a rom or a patch, judged by extension (repeatable, comma-separable)]:FILTER:(rom patch)' \
826
849
  '*--patch=[Patch to check. Repeat once per patch; they are checked in the order given]:PATCHES:_files' \
850
+ '*--patch-select=[Pick which file to use inside the --patch archive before it. Repeatable, one per --patch; falls back to --select]:GLOB:_default' \
827
851
  '*--assume-in=[Take this checksum on trust instead of reading the ROM to compute it, as in crc32=1234abcd (repeatable, comma-separable)]:ALGO=HEX:_default' \
828
852
  '*--expect-in=[Fail unless the ROM matches\: a checksum (crc32=1234abcd), an exact size (size=N), or a floor (min-size=N). Repeatable, comma-separable]:ALGO=HEX:_default' \
829
853
  '--n64-byte-order=[Byte order to put an N64 ROM in before checking\: auto, keep, big-endian, little-endian, or byte-swapped \[default\: auto\]]:N64_BYTE_ORDER:(auto keep big-endian little-endian byte-swapped)' \
@@ -1206,11 +1230,12 @@ _arguments "${_arguments_options[@]}" : \
1206
1230
  _arguments "${_arguments_options[@]}" : \
1207
1231
  '-i+[ROM to patch. May be an archive, a disc sheet (.cue/.gdi), or a bundle]:PATH:_files' \
1208
1232
  '--input=[ROM to patch. May be an archive, a disc sheet (.cue/.gdi), or a bundle]:PATH:_files' \
1209
- '*-s+[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable)]:SELECT:_default' \
1210
- '*--select=[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable)]:SELECT:_default' \
1233
+ '*-s+[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable). --patch-select overrides it for the patch it follows]:SELECT:_default' \
1234
+ '*--select=[Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable). --patch-select overrides it for the patch it follows]:SELECT:_default' \
1211
1235
  '--target=[For a .cue or .gdi input, which track gets the patch. Matched like --select and must hit exactly one track]:TARGET:_default' \
1212
1236
  '*--filter=[Consider only files that look like a rom or a patch, judged by extension (repeatable, comma-separable)]:FILTER:(rom patch)' \
1213
1237
  '*--patch=[Patch to apply. Repeat once per patch; they run in the order given]:PATCHES:_files' \
1238
+ '*--patch-select=[Pick which file to use inside the --patch archive before it. Repeatable, one per --patch; falls back to --select]:GLOB:_default' \
1214
1239
  '-o+[Where to write the patched ROM. Optional when a bundle already names the output]:OUTPUT:_files' \
1215
1240
  '--output=[Where to write the patched ROM. Optional when a bundle already names the output]:OUTPUT:_files' \
1216
1241
  '--bundle=[Follow a rom-weaver-bundle.json recipe\: a file path, or an http(s) URL]:BUNDLE:_files' \
@@ -1282,6 +1307,28 @@ _arguments "${_arguments_options[@]}" : \
1282
1307
  ':shell -- Shell to print completions for:(bash elvish fish powershell zsh)' \
1283
1308
  && ret=0
1284
1309
  ;;
1310
+ (man)
1311
+ _arguments "${_arguments_options[@]}" : \
1312
+ '--man-dir=[Directory to install pages into]:DIR:_files' \
1313
+ '(-v --verbose -q --quiet)--log-level=[How much rom-weaver logs to stderr. Separate from the normal output \[default\: off\]]:LOG_LEVEL:(off error warn info debug trace)' \
1314
+ '--install[Install the generated pages instead of printing one]' \
1315
+ '--json[Print one JSON object per line instead of human-readable output]' \
1316
+ '(--no-progress)--progress[Show progress even when output is piped to a file or another program]' \
1317
+ '(--progress)--no-progress[Hide progress]' \
1318
+ '(--log-level -q --quiet)*-v[Log more\: -v for info, -vv for debug, -vvv for trace]' \
1319
+ '(--log-level -q --quiet)*--verbose[Log more\: -v for info, -vv for debug, -vvv for trace]' \
1320
+ '(--log-level -v --verbose)-q[Log errors only]' \
1321
+ '(--log-level -v --verbose)--quiet[Log errors only]' \
1322
+ '--dep-trace[Also log trace output from bundled libraries (for bug reports)]' \
1323
+ '(--no-color)--color[Keep colors even when output is piped]' \
1324
+ '(--color)--no-color[Turn colors off]' \
1325
+ '-y[Answer yes to every confirmation instead of asking. Does not choose between candidates]' \
1326
+ '--yes[Answer yes to every confirmation instead of asking. Does not choose between candidates]' \
1327
+ '-h[Print help (see more with '\''--help'\'')]' \
1328
+ '--help[Print help (see more with '\''--help'\'')]' \
1329
+ '*::command -- Command path to print:_default' \
1330
+ && ret=0
1331
+ ;;
1285
1332
  (formats)
1286
1333
  _arguments "${_arguments_options[@]}" : \
1287
1334
  '(-v --verbose -q --quiet)--log-level=[How much rom-weaver logs to stderr. Separate from the normal output \[default\: off\]]:LOG_LEVEL:(off error warn info debug trace)' \
@@ -1393,6 +1440,10 @@ esac
1393
1440
  ;;
1394
1441
  esac
1395
1442
  ;;
1443
+ (setup)
1444
+ _arguments "${_arguments_options[@]}" : \
1445
+ && ret=0
1446
+ ;;
1396
1447
  (ingest)
1397
1448
  _arguments "${_arguments_options[@]}" : \
1398
1449
  && ret=0
@@ -1493,6 +1544,10 @@ _arguments "${_arguments_options[@]}" : \
1493
1544
  _arguments "${_arguments_options[@]}" : \
1494
1545
  && ret=0
1495
1546
  ;;
1547
+ (man)
1548
+ _arguments "${_arguments_options[@]}" : \
1549
+ && ret=0
1550
+ ;;
1496
1551
  (formats)
1497
1552
  _arguments "${_arguments_options[@]}" : \
1498
1553
  && ret=0
@@ -1518,6 +1573,7 @@ _rom-weaver_commands() {
1518
1573
  'extract:Unpack an archive or single-payload compressed format' \
1519
1574
  'checksum:Compute checksums for a file, or for a ROM inside an archive' \
1520
1575
  'identify:Identify a ROM title from its checksums' \
1576
+ 'setup:Install the offline identify database' \
1521
1577
  'ingest:Sort a file into ROMs and patches, unpacking and hashing along the way' \
1522
1578
  'compress:Pack files into an archive, disc image, or ROM-specific compressed format' \
1523
1579
  'trim:Cut the padding off a ROM, or put it back' \
@@ -1527,6 +1583,7 @@ _rom-weaver_commands() {
1527
1583
  'plan-extract-batch:Plan a memory-/thread-aware concurrent extraction schedule from per-job source sizes (no I/O)' \
1528
1584
  'weave:Apply one or more patches to a ROM, in order (same as \`patch apply\`)' \
1529
1585
  'completions:Print a tab-completion script for your shell' \
1586
+ 'man:Print or install the generated CLI man pages' \
1530
1587
  'formats:List the formats, codecs, and checksum algorithms this build supports' \
1531
1588
  'help:Print this message or the help of the given subcommand(s)' \
1532
1589
  )
@@ -1619,6 +1676,7 @@ _rom-weaver__subcmd__help_commands() {
1619
1676
  'extract:Unpack an archive or single-payload compressed format' \
1620
1677
  'checksum:Compute checksums for a file, or for a ROM inside an archive' \
1621
1678
  'identify:Identify a ROM title from its checksums' \
1679
+ 'setup:Install the offline identify database' \
1622
1680
  'ingest:Sort a file into ROMs and patches, unpacking and hashing along the way' \
1623
1681
  'compress:Pack files into an archive, disc image, or ROM-specific compressed format' \
1624
1682
  'trim:Cut the padding off a ROM, or put it back' \
@@ -1628,6 +1686,7 @@ _rom-weaver__subcmd__help_commands() {
1628
1686
  'plan-extract-batch:Plan a memory-/thread-aware concurrent extraction schedule from per-job source sizes (no I/O)' \
1629
1687
  'weave:Apply one or more patches to a ROM, in order (same as \`patch apply\`)' \
1630
1688
  'completions:Print a tab-completion script for your shell' \
1689
+ 'man:Print or install the generated CLI man pages' \
1631
1690
  'formats:List the formats, codecs, and checksum algorithms this build supports' \
1632
1691
  'help:Print this message or the help of the given subcommand(s)' \
1633
1692
  )
@@ -1759,6 +1818,11 @@ _rom-weaver__subcmd__help__subcmd__ingest_commands() {
1759
1818
  local commands; commands=()
1760
1819
  _describe -t commands 'rom-weaver help ingest commands' commands "$@"
1761
1820
  }
1821
+ (( $+functions[_rom-weaver__subcmd__help__subcmd__man_commands] )) ||
1822
+ _rom-weaver__subcmd__help__subcmd__man_commands() {
1823
+ local commands; commands=()
1824
+ _describe -t commands 'rom-weaver help man commands' commands "$@"
1825
+ }
1762
1826
  (( $+functions[_rom-weaver__subcmd__help__subcmd__patch_commands] )) ||
1763
1827
  _rom-weaver__subcmd__help__subcmd__patch_commands() {
1764
1828
  local commands; commands=(
@@ -1793,6 +1857,11 @@ _rom-weaver__subcmd__help__subcmd__probe_commands() {
1793
1857
  local commands; commands=()
1794
1858
  _describe -t commands 'rom-weaver help probe commands' commands "$@"
1795
1859
  }
1860
+ (( $+functions[_rom-weaver__subcmd__help__subcmd__setup_commands] )) ||
1861
+ _rom-weaver__subcmd__help__subcmd__setup_commands() {
1862
+ local commands; commands=()
1863
+ _describe -t commands 'rom-weaver help setup commands' commands "$@"
1864
+ }
1796
1865
  (( $+functions[_rom-weaver__subcmd__help__subcmd__tools_commands] )) ||
1797
1866
  _rom-weaver__subcmd__help__subcmd__tools_commands() {
1798
1867
  local commands; commands=(
@@ -2028,6 +2097,11 @@ _rom-weaver__subcmd__ingest_commands() {
2028
2097
  local commands; commands=()
2029
2098
  _describe -t commands 'rom-weaver ingest commands' commands "$@"
2030
2099
  }
2100
+ (( $+functions[_rom-weaver__subcmd__man_commands] )) ||
2101
+ _rom-weaver__subcmd__man_commands() {
2102
+ local commands; commands=()
2103
+ _describe -t commands 'rom-weaver man commands' commands "$@"
2104
+ }
2031
2105
  (( $+functions[_rom-weaver__subcmd__patch_commands] )) ||
2032
2106
  _rom-weaver__subcmd__patch_commands() {
2033
2107
  local commands; commands=(
@@ -2094,6 +2168,11 @@ _rom-weaver__subcmd__probe_commands() {
2094
2168
  local commands; commands=()
2095
2169
  _describe -t commands 'rom-weaver probe commands' commands "$@"
2096
2170
  }
2171
+ (( $+functions[_rom-weaver__subcmd__setup_commands] )) ||
2172
+ _rom-weaver__subcmd__setup_commands() {
2173
+ local commands; commands=()
2174
+ _describe -t commands 'rom-weaver setup commands' commands "$@"
2175
+ }
2097
2176
  (( $+functions[_rom-weaver__subcmd__tools_commands] )) ||
2098
2177
  _rom-weaver__subcmd__tools_commands() {
2099
2178
  local commands; commands=(
@@ -46,6 +46,9 @@ _rom__weaver() {
46
46
  rom__weaver,inspect)
47
47
  cmd="rom__weaver__subcmd__probe"
48
48
  ;;
49
+ rom__weaver,man)
50
+ cmd="rom__weaver__subcmd__man"
51
+ ;;
49
52
  rom__weaver,patch)
50
53
  cmd="rom__weaver__subcmd__patch"
51
54
  ;;
@@ -55,6 +58,9 @@ _rom__weaver() {
55
58
  rom__weaver,probe)
56
59
  cmd="rom__weaver__subcmd__probe"
57
60
  ;;
61
+ rom__weaver,setup)
62
+ cmd="rom__weaver__subcmd__setup"
63
+ ;;
58
64
  rom__weaver,tools)
59
65
  cmd="rom__weaver__subcmd__tools"
60
66
  ;;
@@ -115,6 +121,9 @@ _rom__weaver() {
115
121
  rom__weaver__subcmd__help,ingest)
116
122
  cmd="rom__weaver__subcmd__help__subcmd__ingest"
117
123
  ;;
124
+ rom__weaver__subcmd__help,man)
125
+ cmd="rom__weaver__subcmd__help__subcmd__man"
126
+ ;;
118
127
  rom__weaver__subcmd__help,patch)
119
128
  cmd="rom__weaver__subcmd__help__subcmd__patch"
120
129
  ;;
@@ -124,6 +133,9 @@ _rom__weaver() {
124
133
  rom__weaver__subcmd__help,probe)
125
134
  cmd="rom__weaver__subcmd__help__subcmd__probe"
126
135
  ;;
136
+ rom__weaver__subcmd__help,setup)
137
+ cmd="rom__weaver__subcmd__help__subcmd__setup"
138
+ ;;
127
139
  rom__weaver__subcmd__help,tools)
128
140
  cmd="rom__weaver__subcmd__help__subcmd__tools"
129
141
  ;;
@@ -329,7 +341,7 @@ _rom__weaver() {
329
341
 
330
342
  case "${cmd}" in
331
343
  rom__weaver)
332
- opts="-v -q -y -h -V --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help --version probe inspect extract checksum identify ingest compress trim patch bundle tools plan-extract-batch weave completions formats help"
344
+ opts="-v -q -y -h -V --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help --version probe inspect extract checksum identify setup ingest compress trim patch bundle tools plan-extract-batch weave completions man formats help"
333
345
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 1 ]] ; then
334
346
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
335
347
  return 0
@@ -875,7 +887,7 @@ _rom__weaver() {
875
887
  return 0
876
888
  ;;
877
889
  rom__subcmd__weaver__subcmd__help)
878
- opts="probe extract checksum identify ingest compress trim patch bundle tools plan-extract-batch weave completions formats help"
890
+ opts="probe extract checksum identify setup ingest compress trim patch bundle tools plan-extract-batch weave completions man formats help"
879
891
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
880
892
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
881
893
  return 0
@@ -1196,6 +1208,20 @@ _rom__weaver() {
1196
1208
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
1197
1209
  return 0
1198
1210
  ;;
1211
+ rom__subcmd__weaver__subcmd__help__subcmd__man)
1212
+ opts=""
1213
+ if [[ ${cur} == -* || ${COMP_CWORD} -eq 3 ]] ; then
1214
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
1215
+ return 0
1216
+ fi
1217
+ case "${prev}" in
1218
+ *)
1219
+ COMPREPLY=()
1220
+ ;;
1221
+ esac
1222
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
1223
+ return 0
1224
+ ;;
1199
1225
  rom__subcmd__weaver__subcmd__help__subcmd__patch)
1200
1226
  opts="apply validate create"
1201
1227
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 3 ]] ; then
@@ -1280,6 +1306,20 @@ _rom__weaver() {
1280
1306
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
1281
1307
  return 0
1282
1308
  ;;
1309
+ rom__subcmd__weaver__subcmd__help__subcmd__setup)
1310
+ opts=""
1311
+ if [[ ${cur} == -* || ${COMP_CWORD} -eq 3 ]] ; then
1312
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
1313
+ return 0
1314
+ fi
1315
+ case "${prev}" in
1316
+ *)
1317
+ COMPREPLY=()
1318
+ ;;
1319
+ esac
1320
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
1321
+ return 0
1322
+ ;;
1283
1323
  rom__subcmd__weaver__subcmd__help__subcmd__tools)
1284
1324
  opts="ppf-undo"
1285
1325
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 3 ]] ; then
@@ -2030,6 +2070,28 @@ _rom__weaver() {
2030
2070
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
2031
2071
  return 0
2032
2072
  ;;
2073
+ rom__subcmd__weaver__subcmd__man)
2074
+ opts="-v -q -y -h --install --man-dir --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help"
2075
+ if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
2076
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
2077
+ return 0
2078
+ fi
2079
+ case "${prev}" in
2080
+ --man-dir)
2081
+ COMPREPLY=($(compgen -f "${cur}"))
2082
+ return 0
2083
+ ;;
2084
+ --log-level)
2085
+ COMPREPLY=($(compgen -W "off error warn info debug trace" -- "${cur}"))
2086
+ return 0
2087
+ ;;
2088
+ *)
2089
+ COMPREPLY=()
2090
+ ;;
2091
+ esac
2092
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
2093
+ return 0
2094
+ ;;
2033
2095
  rom__subcmd__weaver__subcmd__patch)
2034
2096
  opts="-v -q -y -h --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help apply weave validate create help"
2035
2097
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
@@ -2049,7 +2111,7 @@ _rom__weaver() {
2049
2111
  return 0
2050
2112
  ;;
2051
2113
  rom__subcmd__weaver__subcmd__patch__subcmd__apply)
2052
- opts="-i -s -o -j -n -v -q -y -h --input --select --target --filter --no-extract --no-ignore --patch --output --bundle --with --without --raw --no-compress --format --compress-format --codec --compress-codec --level --compress-level --assume-in --expect-in --patch-header --patch-basis --output-header --repair-checksum --n64-byte-order --ignore-checksum-validation --expect-out --code --code-system --code-kind --emit-bundle --tui --threads --force --dry-run --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help"
2114
+ opts="-i -s -o -j -n -v -q -y -h --input --select --target --filter --no-extract --no-ignore --patch --patch-select --output --bundle --with --without --raw --no-compress --format --compress-format --codec --compress-codec --level --compress-level --assume-in --expect-in --patch-header --patch-basis --output-header --repair-checksum --n64-byte-order --ignore-checksum-validation --expect-out --code --code-system --code-kind --emit-bundle --tui --threads --force --dry-run --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help"
2053
2115
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 3 ]] ; then
2054
2116
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
2055
2117
  return 0
@@ -2083,6 +2145,10 @@ _rom__weaver() {
2083
2145
  COMPREPLY=($(compgen -f "${cur}"))
2084
2146
  return 0
2085
2147
  ;;
2148
+ --patch-select)
2149
+ COMPREPLY=($(compgen -f "${cur}"))
2150
+ return 0
2151
+ ;;
2086
2152
  --output)
2087
2153
  COMPREPLY=($(compgen -f "${cur}"))
2088
2154
  return 0
@@ -2359,7 +2425,7 @@ _rom__weaver() {
2359
2425
  return 0
2360
2426
  ;;
2361
2427
  rom__subcmd__weaver__subcmd__patch__subcmd__validate)
2362
- opts="-i -s -j -v -q -y -h --input --select --filter --no-extract --no-ignore --patch --assume-in --expect-in --strip-header --n64-byte-order --ignore-checksum-validation --independent --plan --patch-basis --patch-input-check --patch-output-check --threads --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help"
2428
+ opts="-i -s -j -v -q -y -h --input --select --filter --no-extract --no-ignore --patch --patch-select --assume-in --expect-in --strip-header --n64-byte-order --ignore-checksum-validation --independent --plan --patch-basis --patch-input-check --patch-output-check --threads --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help"
2363
2429
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 3 ]] ; then
2364
2430
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
2365
2431
  return 0
@@ -2389,6 +2455,10 @@ _rom__weaver() {
2389
2455
  COMPREPLY=($(compgen -f "${cur}"))
2390
2456
  return 0
2391
2457
  ;;
2458
+ --patch-select)
2459
+ COMPREPLY=($(compgen -f "${cur}"))
2460
+ return 0
2461
+ ;;
2392
2462
  --assume-in)
2393
2463
  COMPREPLY=($(compgen -f "${cur}"))
2394
2464
  return 0
@@ -2512,6 +2582,28 @@ _rom__weaver() {
2512
2582
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
2513
2583
  return 0
2514
2584
  ;;
2585
+ rom__subcmd__weaver__subcmd__setup)
2586
+ opts="-v -q -y -h --database-dir --force --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help"
2587
+ if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
2588
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
2589
+ return 0
2590
+ fi
2591
+ case "${prev}" in
2592
+ --database-dir)
2593
+ COMPREPLY=($(compgen -f "${cur}"))
2594
+ return 0
2595
+ ;;
2596
+ --log-level)
2597
+ COMPREPLY=($(compgen -W "off error warn info debug trace" -- "${cur}"))
2598
+ return 0
2599
+ ;;
2600
+ *)
2601
+ COMPREPLY=()
2602
+ ;;
2603
+ esac
2604
+ COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
2605
+ return 0
2606
+ ;;
2515
2607
  rom__subcmd__weaver__subcmd__tools)
2516
2608
  opts="-v -q -y -h --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help ppf-undo help"
2517
2609
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
@@ -2665,7 +2757,7 @@ _rom__weaver() {
2665
2757
  return 0
2666
2758
  ;;
2667
2759
  rom__subcmd__weaver__subcmd__weave)
2668
- opts="-i -s -o -j -n -v -q -y -h --input --select --target --filter --no-extract --no-ignore --patch --output --bundle --with --without --raw --no-compress --format --compress-format --codec --compress-codec --level --compress-level --assume-in --expect-in --patch-header --patch-basis --output-header --repair-checksum --n64-byte-order --ignore-checksum-validation --expect-out --code --code-system --code-kind --emit-bundle --tui --threads --force --dry-run --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help"
2760
+ opts="-i -s -o -j -n -v -q -y -h --input --select --target --filter --no-extract --no-ignore --patch --patch-select --output --bundle --with --without --raw --no-compress --format --compress-format --codec --compress-codec --level --compress-level --assume-in --expect-in --patch-header --patch-basis --output-header --repair-checksum --n64-byte-order --ignore-checksum-validation --expect-out --code --code-system --code-kind --emit-bundle --tui --threads --force --dry-run --json --progress --no-progress --log-level --verbose --quiet --dep-trace --color --no-color --yes --help"
2669
2761
  if [[ ${cur} == -* || ${COMP_CWORD} -eq 2 ]] ; then
2670
2762
  COMPREPLY=( $(compgen -W "${opts}" -- "${cur}") )
2671
2763
  return 0
@@ -2699,6 +2791,10 @@ _rom__weaver() {
2699
2791
  COMPREPLY=($(compgen -f "${cur}"))
2700
2792
  return 0
2701
2793
  ;;
2794
+ --patch-select)
2795
+ COMPREPLY=($(compgen -f "${cur}"))
2796
+ return 0
2797
+ ;;
2702
2798
  --output)
2703
2799
  COMPREPLY=($(compgen -f "${cur}"))
2704
2800
  return 0