@rom-weaver/cli 0.10.1 → 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.
- package/README.md +34 -10
- package/docs/completions/_rom-weaver +1288 -0
- package/docs/completions/rom-weaver.bash +1817 -0
- package/docs/completions/rom-weaver.elv +763 -0
- package/docs/completions/rom-weaver.fish +723 -0
- package/docs/completions/rom-weaver.ps1 +824 -0
- package/docs/man/rom-weaver-bundle-create.1 +213 -0
- package/docs/man/rom-weaver-bundle-parse.1 +98 -0
- package/docs/man/rom-weaver-bundle-schema.1 +67 -0
- package/docs/man/rom-weaver-bundle.1 +69 -0
- package/docs/man/rom-weaver-checksum.1 +110 -0
- package/docs/man/rom-weaver-completions.1 +84 -0
- package/docs/man/rom-weaver-compress.1 +125 -0
- package/docs/man/rom-weaver-extract.1 +111 -0
- package/docs/man/rom-weaver-ingest.1 +98 -0
- package/docs/man/rom-weaver-patch-apply.1 +356 -0
- package/docs/man/rom-weaver-patch-create.1 +166 -0
- package/docs/man/rom-weaver-patch-validate.1 +161 -0
- package/docs/man/rom-weaver-patch.1 +69 -0
- package/docs/man/rom-weaver-probe.1 +93 -0
- package/docs/man/rom-weaver-tools-ppf-undo.1 +71 -0
- package/docs/man/rom-weaver-tools.1 +63 -0
- package/docs/man/rom-weaver-trim.1 +111 -0
- package/docs/man/rom-weaver-weave.1 +356 -0
- package/docs/man/rom-weaver.1 +124 -0
- package/package.json +11 -10
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
.ie \n(.g .ds Aq \(aq
|
|
2
|
+
.el .ds Aq '
|
|
3
|
+
.TH rom-weaver-compress 1 "rom-weaver-compress "
|
|
4
|
+
.SH NAME
|
|
5
|
+
rom\-weaver\-compress \- Pack files into an archive or a compressed disc image
|
|
6
|
+
.SH SYNOPSIS
|
|
7
|
+
\fBrom\-weaver compress\fR <\fB\-i\fR|\fB\-\-input\fR> [\fB\-\-json\fR] [\fB\-f\fR|\fB\-\-format\fR] [\fB\-\-progress\fR] [\fB\-\-no\-progress\fR] <\fB\-o\fR|\fB\-\-output\fR> [\fB\-\-codec\fR] [\fB\-\-log\-level\fR] [\fB\-\-level\fR] [\fB\-v\fR|\fB\-\-verbose\fR]... [\fB\-j\fR|\fB\-\-threads\fR] [\fB\-q\fR|\fB\-\-quiet\fR] [\fB\-\-dep\-trace\fR] [\fB\-\-color\fR] [\fB\-\-no\-color\fR] [\fB\-h\fR|\fB\-\-help\fR]
|
|
8
|
+
.SH DESCRIPTION
|
|
9
|
+
Pack files into an archive or a compressed disc image.
|
|
10
|
+
.PP
|
|
11
|
+
The format comes from the \-\-output extension, so `\-\-output game.chd` writes a
|
|
12
|
+
CHD. Formats that can be written: zip, 7z, chd, rvz, and z3ds.
|
|
13
|
+
.PP
|
|
14
|
+
Repeat \-\-input to put several files in one archive. Disc images take a single
|
|
15
|
+
input instead: point \-\-input at the .cue or .gdi and its tracks come along.
|
|
16
|
+
.PP
|
|
17
|
+
rom\-weaver compress \-\-input game.cue \-\-output game.chd
|
|
18
|
+
.PP
|
|
19
|
+
Each format picks a suitable codec on its own; \-\-codec and \-\-level are there
|
|
20
|
+
for when you want to override that.
|
|
21
|
+
.SH OPTIONS
|
|
22
|
+
.TP
|
|
23
|
+
\fB\-i\fR, \fB\-\-input\fR \fI<INPUT>\fR
|
|
24
|
+
File to put in the archive; repeat for each one. For a disc image, pass the .cue or .gdi alone and its tracks come along
|
|
25
|
+
.TP
|
|
26
|
+
\fB\-f\fR, \fB\-\-format\fR \fI<FORMAT>\fR
|
|
27
|
+
Output format, such as zip, 7z, chd, rvz, or z3ds.
|
|
28
|
+
|
|
29
|
+
Normally you do not need this: the format comes from the \-\-output extension.
|
|
30
|
+
Pass it when the output name has no usable extension. If it disagrees with the
|
|
31
|
+
extension, this flag wins and a warning is printed.
|
|
32
|
+
|
|
33
|
+
Common alternate spellings are accepted, so `7zip` works as well as `7z` and
|
|
34
|
+
`3ds` as well as `z3ds`. The CLI guide lists every alias.
|
|
35
|
+
.TP
|
|
36
|
+
\fB\-o\fR, \fB\-\-output\fR \fI<PATH>\fR
|
|
37
|
+
Where to write the archive
|
|
38
|
+
.TP
|
|
39
|
+
\fB\-\-codec\fR \fI<CODEC>\fR
|
|
40
|
+
Compression method to use, written as codec or codec:level.
|
|
41
|
+
|
|
42
|
+
Each format has its own codecs, and each picks a sensible one on its own, so
|
|
43
|
+
this is only for overriding that choice. CHD takes a list, tried in order:
|
|
44
|
+
|
|
45
|
+
\-\-codec cdzs:19,cdzl,cdfl
|
|
46
|
+
|
|
47
|
+
Without :level, a codec follows the \-\-level profile.
|
|
48
|
+
|
|
49
|
+
Only the codec names a format actually supports are accepted; there are no
|
|
50
|
+
cross\-format synonyms. The CLI guide lists them per format.
|
|
51
|
+
.TP
|
|
52
|
+
\fB\-\-level\fR \fI<LEVEL>\fR [default: max]
|
|
53
|
+
How hard to compress: min, very\-low, low, medium, high, very\-high, or max
|
|
54
|
+
.br
|
|
55
|
+
|
|
56
|
+
.br
|
|
57
|
+
\fIPossible values:\fR
|
|
58
|
+
.RS 14
|
|
59
|
+
.IP \(bu 2
|
|
60
|
+
min
|
|
61
|
+
.IP \(bu 2
|
|
62
|
+
very\-low
|
|
63
|
+
.IP \(bu 2
|
|
64
|
+
low
|
|
65
|
+
.IP \(bu 2
|
|
66
|
+
medium
|
|
67
|
+
.IP \(bu 2
|
|
68
|
+
high
|
|
69
|
+
.IP \(bu 2
|
|
70
|
+
very\-high
|
|
71
|
+
.IP \(bu 2
|
|
72
|
+
max
|
|
73
|
+
.RE
|
|
74
|
+
.TP
|
|
75
|
+
\fB\-j\fR, \fB\-\-threads\fR \fI<auto|N>\fR [default: auto]
|
|
76
|
+
How many threads to use at most. auto uses every core; a format may still use fewer
|
|
77
|
+
.TP
|
|
78
|
+
\fB\-h\fR, \fB\-\-help\fR
|
|
79
|
+
Print help (see a summary with \*(Aq\-h\*(Aq)
|
|
80
|
+
.SH "GLOBAL OPTIONS"
|
|
81
|
+
.TP
|
|
82
|
+
\fB\-\-json\fR
|
|
83
|
+
Print one JSON object per line instead of human\-readable output
|
|
84
|
+
.TP
|
|
85
|
+
\fB\-\-progress\fR
|
|
86
|
+
Show progress even when output is piped to a file or another program
|
|
87
|
+
.TP
|
|
88
|
+
\fB\-\-no\-progress\fR
|
|
89
|
+
Hide progress
|
|
90
|
+
.TP
|
|
91
|
+
\fB\-\-log\-level\fR \fI<LOG_LEVEL>\fR
|
|
92
|
+
How much rom\-weaver logs to stderr. Separate from the normal output [default: off]
|
|
93
|
+
.br
|
|
94
|
+
|
|
95
|
+
.br
|
|
96
|
+
\fIPossible values:\fR
|
|
97
|
+
.RS 14
|
|
98
|
+
.IP \(bu 2
|
|
99
|
+
off
|
|
100
|
+
.IP \(bu 2
|
|
101
|
+
error
|
|
102
|
+
.IP \(bu 2
|
|
103
|
+
warn
|
|
104
|
+
.IP \(bu 2
|
|
105
|
+
info
|
|
106
|
+
.IP \(bu 2
|
|
107
|
+
debug
|
|
108
|
+
.IP \(bu 2
|
|
109
|
+
trace
|
|
110
|
+
.RE
|
|
111
|
+
.TP
|
|
112
|
+
\fB\-v\fR, \fB\-\-verbose\fR
|
|
113
|
+
Log more: \-v for info, \-vv for debug, \-vvv for trace
|
|
114
|
+
.TP
|
|
115
|
+
\fB\-q\fR, \fB\-\-quiet\fR
|
|
116
|
+
Log errors only
|
|
117
|
+
.TP
|
|
118
|
+
\fB\-\-dep\-trace\fR
|
|
119
|
+
Also log trace output from bundled libraries (for bug reports)
|
|
120
|
+
.TP
|
|
121
|
+
\fB\-\-color\fR
|
|
122
|
+
Keep colors even when output is piped
|
|
123
|
+
.TP
|
|
124
|
+
\fB\-\-no\-color\fR
|
|
125
|
+
Turn colors off
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
.ie \n(.g .ds Aq \(aq
|
|
2
|
+
.el .ds Aq '
|
|
3
|
+
.TH rom-weaver-extract 1 "rom-weaver-extract "
|
|
4
|
+
.SH NAME
|
|
5
|
+
rom\-weaver\-extract \- Unpack an archive or disc image
|
|
6
|
+
.SH SYNOPSIS
|
|
7
|
+
\fBrom\-weaver extract\fR <\fB\-i\fR|\fB\-\-input\fR> [\fB\-\-json\fR] [\fB\-\-progress\fR] [\fB\-s\fR|\fB\-\-select\fR] [\fB\-\-filter\fR] [\fB\-\-no\-progress\fR] [\fB\-\-log\-level\fR] <\fB\-o\fR|\fB\-\-output\fR> [\fB\-\-split\-bin\fR] [\fB\-v\fR|\fB\-\-verbose\fR]... [\fB\-\-no\-ignore\fR] [\fB\-q\fR|\fB\-\-quiet\fR] [\fB\-\-dep\-trace\fR] [\fB\-\-no\-nested\-extract\fR] [\fB\-\-color\fR] [\fB\-\-force\fR] [\fB\-\-checksum\fR] [\fB\-\-no\-color\fR] [\fB\-\-checksum\-rom\fR] [\fB\-\-probe\fR] [\fB\-j\fR|\fB\-\-threads\fR] [\fB\-h\fR|\fB\-\-help\fR]
|
|
8
|
+
.SH DESCRIPTION
|
|
9
|
+
Unpack an archive or disc image into a directory.
|
|
10
|
+
.PP
|
|
11
|
+
Archives found inside the input are unpacked too, up to eight levels deep. Pass
|
|
12
|
+
\-\-no\-nested\-extract to stop after the first layer.
|
|
13
|
+
.PP
|
|
14
|
+
Existing files are never overwritten: if any output file is already there, the
|
|
15
|
+
whole extraction stops before writing. Pass \-\-force to overwrite instead.
|
|
16
|
+
.SH OPTIONS
|
|
17
|
+
.TP
|
|
18
|
+
\fB\-i\fR, \fB\-\-input\fR \fI<INPUT>\fR
|
|
19
|
+
Archive or disc image to unpack
|
|
20
|
+
.TP
|
|
21
|
+
\fB\-s\fR, \fB\-\-select\fR \fI<SELECT>\fR
|
|
22
|
+
Extract only these files, by exact name, prefix, or glob (repeatable). For example: \-\-select \*(Aqgame.disc0?.bin\*(Aq
|
|
23
|
+
.TP
|
|
24
|
+
\fB\-\-filter\fR \fI<FILTER>\fR
|
|
25
|
+
Extract only files that look like a rom or a patch, judged by extension (repeatable, comma\-separable)
|
|
26
|
+
.br
|
|
27
|
+
|
|
28
|
+
.br
|
|
29
|
+
\fIPossible values:\fR
|
|
30
|
+
.RS 14
|
|
31
|
+
.IP \(bu 2
|
|
32
|
+
rom
|
|
33
|
+
.IP \(bu 2
|
|
34
|
+
patch
|
|
35
|
+
.RE
|
|
36
|
+
.TP
|
|
37
|
+
\fB\-o\fR, \fB\-\-output\fR \fI<DIR>\fR
|
|
38
|
+
Directory to write the extracted files into
|
|
39
|
+
.TP
|
|
40
|
+
\fB\-\-split\-bin\fR
|
|
41
|
+
Write a CD\-format CHD as a CUE plus one BIN per track (*.trackNN.bin), rather than one merged BIN
|
|
42
|
+
.TP
|
|
43
|
+
\fB\-\-no\-ignore\fR
|
|
44
|
+
Also consider files normally skipped inside archives: readmes, images, checksum sidecars, and OS clutter such as .DS_Store
|
|
45
|
+
.TP
|
|
46
|
+
\fB\-\-no\-nested\-extract\fR
|
|
47
|
+
Stop after one layer; leave any archive found inside the input packed
|
|
48
|
+
.TP
|
|
49
|
+
\fB\-\-force\fR
|
|
50
|
+
Overwrite files already in the output directory (without this, extraction stops instead)
|
|
51
|
+
.TP
|
|
52
|
+
\fB\-\-checksum\fR \fI<ALGO>\fR
|
|
53
|
+
Also hash every extracted file (repeatable, comma\-separable)
|
|
54
|
+
.TP
|
|
55
|
+
\fB\-\-checksum\-rom\fR \fI<ALGO>\fR
|
|
56
|
+
Like \-\-checksum, but hash only the ROMs and skip sidecar files. Ignored when \-\-checksum is also given
|
|
57
|
+
.TP
|
|
58
|
+
\fB\-\-probe\fR
|
|
59
|
+
Also report the format and platform of what was extracted, and fail if a lone payload matches no known platform
|
|
60
|
+
.TP
|
|
61
|
+
\fB\-j\fR, \fB\-\-threads\fR \fI<auto|N>\fR [default: auto]
|
|
62
|
+
How many threads to use at most. auto uses every core; a format may still use fewer
|
|
63
|
+
.TP
|
|
64
|
+
\fB\-h\fR, \fB\-\-help\fR
|
|
65
|
+
Print help (see a summary with \*(Aq\-h\*(Aq)
|
|
66
|
+
.SH "GLOBAL OPTIONS"
|
|
67
|
+
.TP
|
|
68
|
+
\fB\-\-json\fR
|
|
69
|
+
Print one JSON object per line instead of human\-readable output
|
|
70
|
+
.TP
|
|
71
|
+
\fB\-\-progress\fR
|
|
72
|
+
Show progress even when output is piped to a file or another program
|
|
73
|
+
.TP
|
|
74
|
+
\fB\-\-no\-progress\fR
|
|
75
|
+
Hide progress
|
|
76
|
+
.TP
|
|
77
|
+
\fB\-\-log\-level\fR \fI<LOG_LEVEL>\fR
|
|
78
|
+
How much rom\-weaver logs to stderr. Separate from the normal output [default: off]
|
|
79
|
+
.br
|
|
80
|
+
|
|
81
|
+
.br
|
|
82
|
+
\fIPossible values:\fR
|
|
83
|
+
.RS 14
|
|
84
|
+
.IP \(bu 2
|
|
85
|
+
off
|
|
86
|
+
.IP \(bu 2
|
|
87
|
+
error
|
|
88
|
+
.IP \(bu 2
|
|
89
|
+
warn
|
|
90
|
+
.IP \(bu 2
|
|
91
|
+
info
|
|
92
|
+
.IP \(bu 2
|
|
93
|
+
debug
|
|
94
|
+
.IP \(bu 2
|
|
95
|
+
trace
|
|
96
|
+
.RE
|
|
97
|
+
.TP
|
|
98
|
+
\fB\-v\fR, \fB\-\-verbose\fR
|
|
99
|
+
Log more: \-v for info, \-vv for debug, \-vvv for trace
|
|
100
|
+
.TP
|
|
101
|
+
\fB\-q\fR, \fB\-\-quiet\fR
|
|
102
|
+
Log errors only
|
|
103
|
+
.TP
|
|
104
|
+
\fB\-\-dep\-trace\fR
|
|
105
|
+
Also log trace output from bundled libraries (for bug reports)
|
|
106
|
+
.TP
|
|
107
|
+
\fB\-\-color\fR
|
|
108
|
+
Keep colors even when output is piped
|
|
109
|
+
.TP
|
|
110
|
+
\fB\-\-no\-color\fR
|
|
111
|
+
Turn colors off
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
.ie \n(.g .ds Aq \(aq
|
|
2
|
+
.el .ds Aq '
|
|
3
|
+
.TH rom-weaver-ingest 1 "rom-weaver-ingest "
|
|
4
|
+
.SH NAME
|
|
5
|
+
rom\-weaver\-ingest \- Sort a file into ROMs and patches, unpacking and hashing along the way
|
|
6
|
+
.SH SYNOPSIS
|
|
7
|
+
\fBrom\-weaver ingest\fR <\fB\-i\fR|\fB\-\-input\fR> [\fB\-\-json\fR] <\fB\-o\fR|\fB\-\-output\fR> [\fB\-\-progress\fR] [\fB\-\-no\-progress\fR] [\fB\-s\fR|\fB\-\-select\fR] [\fB\-\-log\-level\fR] [\fB\-v\fR|\fB\-\-verbose\fR]... [\fB\-\-no\-ignore\fR] [\fB\-q\fR|\fB\-\-quiet\fR] [\fB\-\-dep\-trace\fR] [\fB\-\-no\-nested\-extract\fR] [\fB\-\-color\fR] [\fB\-\-split\-bin\fR] [\fB\-\-checksum\fR] [\fB\-\-no\-color\fR] [\fB\-j\fR|\fB\-\-threads\fR] [\fB\-h\fR|\fB\-\-help\fR]
|
|
8
|
+
.SH DESCRIPTION
|
|
9
|
+
Sort a file into ROMs and patches, unpacking archives and hashing the ROMs as
|
|
10
|
+
it goes.
|
|
11
|
+
.PP
|
|
12
|
+
This is what the webapp runs when you drop a file on it, and it is the command
|
|
13
|
+
to reach for when you do not know what you have. For a description without the
|
|
14
|
+
unpacking, use `probe`.
|
|
15
|
+
.SH OPTIONS
|
|
16
|
+
.TP
|
|
17
|
+
\fB\-i\fR, \fB\-\-input\fR \fI<INPUT>\fR
|
|
18
|
+
File to sort into ROMs and patches
|
|
19
|
+
.TP
|
|
20
|
+
\fB\-o\fR, \fB\-\-output\fR \fI<DIR>\fR
|
|
21
|
+
Directory to write anything unpacked along the way into
|
|
22
|
+
.TP
|
|
23
|
+
\fB\-s\fR, \fB\-\-select\fR \fI<SELECT>\fR
|
|
24
|
+
Pick which ROM to use when the archive holds more than one, by exact name, prefix, or glob (repeatable)
|
|
25
|
+
.TP
|
|
26
|
+
\fB\-\-no\-ignore\fR
|
|
27
|
+
Also consider files normally skipped inside archives: readmes, images, checksum sidecars, and OS clutter such as .DS_Store
|
|
28
|
+
.TP
|
|
29
|
+
\fB\-\-no\-nested\-extract\fR
|
|
30
|
+
Stop after one layer; leave any archive found inside the input packed
|
|
31
|
+
.TP
|
|
32
|
+
\fB\-\-split\-bin\fR [\fI<SPLIT_BIN>\fR]
|
|
33
|
+
For a multi\-track CD\-format CHD, write one BIN per track (\-\-split\-bin) or one merged BIN (\-\-split\-bin false). Omit to be asked
|
|
34
|
+
.br
|
|
35
|
+
|
|
36
|
+
.br
|
|
37
|
+
\fIPossible values:\fR
|
|
38
|
+
.RS 14
|
|
39
|
+
.IP \(bu 2
|
|
40
|
+
true
|
|
41
|
+
.IP \(bu 2
|
|
42
|
+
false
|
|
43
|
+
.RE
|
|
44
|
+
.TP
|
|
45
|
+
\fB\-\-checksum\fR \fI<ALGO>\fR
|
|
46
|
+
Which checksums to compute for each ROM found (repeatable, comma\-separable) [default: crc32,md5,sha1]
|
|
47
|
+
.TP
|
|
48
|
+
\fB\-j\fR, \fB\-\-threads\fR \fI<auto|N>\fR [default: auto]
|
|
49
|
+
How many threads to use at most. auto uses every core; a format may still use fewer
|
|
50
|
+
.TP
|
|
51
|
+
\fB\-h\fR, \fB\-\-help\fR
|
|
52
|
+
Print help (see a summary with \*(Aq\-h\*(Aq)
|
|
53
|
+
.SH "GLOBAL OPTIONS"
|
|
54
|
+
.TP
|
|
55
|
+
\fB\-\-json\fR
|
|
56
|
+
Print one JSON object per line instead of human\-readable output
|
|
57
|
+
.TP
|
|
58
|
+
\fB\-\-progress\fR
|
|
59
|
+
Show progress even when output is piped to a file or another program
|
|
60
|
+
.TP
|
|
61
|
+
\fB\-\-no\-progress\fR
|
|
62
|
+
Hide progress
|
|
63
|
+
.TP
|
|
64
|
+
\fB\-\-log\-level\fR \fI<LOG_LEVEL>\fR
|
|
65
|
+
How much rom\-weaver logs to stderr. Separate from the normal output [default: off]
|
|
66
|
+
.br
|
|
67
|
+
|
|
68
|
+
.br
|
|
69
|
+
\fIPossible values:\fR
|
|
70
|
+
.RS 14
|
|
71
|
+
.IP \(bu 2
|
|
72
|
+
off
|
|
73
|
+
.IP \(bu 2
|
|
74
|
+
error
|
|
75
|
+
.IP \(bu 2
|
|
76
|
+
warn
|
|
77
|
+
.IP \(bu 2
|
|
78
|
+
info
|
|
79
|
+
.IP \(bu 2
|
|
80
|
+
debug
|
|
81
|
+
.IP \(bu 2
|
|
82
|
+
trace
|
|
83
|
+
.RE
|
|
84
|
+
.TP
|
|
85
|
+
\fB\-v\fR, \fB\-\-verbose\fR
|
|
86
|
+
Log more: \-v for info, \-vv for debug, \-vvv for trace
|
|
87
|
+
.TP
|
|
88
|
+
\fB\-q\fR, \fB\-\-quiet\fR
|
|
89
|
+
Log errors only
|
|
90
|
+
.TP
|
|
91
|
+
\fB\-\-dep\-trace\fR
|
|
92
|
+
Also log trace output from bundled libraries (for bug reports)
|
|
93
|
+
.TP
|
|
94
|
+
\fB\-\-color\fR
|
|
95
|
+
Keep colors even when output is piped
|
|
96
|
+
.TP
|
|
97
|
+
\fB\-\-no\-color\fR
|
|
98
|
+
Turn colors off
|
|
@@ -0,0 +1,356 @@
|
|
|
1
|
+
.ie \n(.g .ds Aq \(aq
|
|
2
|
+
.el .ds Aq '
|
|
3
|
+
.TH rom-weaver-patch-apply 1 "rom-weaver-patch-apply "
|
|
4
|
+
.SH NAME
|
|
5
|
+
rom\-weaver\-patch\-apply \- Apply one or more patches to a ROM, in order
|
|
6
|
+
.SH SYNOPSIS
|
|
7
|
+
\fBrom\-weaver patch apply\fR <\fB\-i\fR|\fB\-\-input\fR> [\fB\-\-json\fR] [\fB\-\-progress\fR] [\fB\-s\fR|\fB\-\-select\fR] [\fB\-\-no\-progress\fR] [\fB\-\-target\fR] [\fB\-\-filter\fR] [\fB\-\-log\-level\fR] [\fB\-\-no\-extract\fR] [\fB\-v\fR|\fB\-\-verbose\fR]... [\fB\-\-no\-ignore\fR] [\fB\-q\fR|\fB\-\-quiet\fR] [\fB\-\-dep\-trace\fR] [\fB\-\-patch\fR] [\fB\-\-color\fR] [\fB\-o\fR|\fB\-\-output\fR] [\fB\-\-bundle\fR] [\fB\-\-no\-color\fR] [\fB\-\-with\fR] [\fB\-\-without\fR] [\fB\-\-no\-compress\fR] [\fB\-\-compress\-format\fR] [\fB\-\-compress\-codec\fR] [\fB\-\-compress\-level\fR] [\fB\-\-assume\-in\fR] [\fB\-\-expect\-in\fR] [\fB\-\-patch\-header\fR] [\fB\-\-patch\-basis\fR] [\fB\-\-output\-header\fR] [\fB\-\-repair\-checksum\fR] [\fB\-\-n64\-byte\-order\fR] [\fB\-\-ignore\-checksum\-validation\fR] [\fB\-\-expect\-out\fR] [\fB\-\-code\fR] [\fB\-\-code\-system\fR] [\fB\-\-code\-kind\fR] [\fB\-\-emit\-bundle\fR] [\fB\-\-tui\fR] [\fB\-j\fR|\fB\-\-threads\fR] [\fB\-h\fR|\fB\-\-help\fR]
|
|
8
|
+
.SH DESCRIPTION
|
|
9
|
+
Apply one or more patches to a ROM, in order.
|
|
10
|
+
.PP
|
|
11
|
+
`rom\-weaver weave` runs this same command under a shorter name, and is what
|
|
12
|
+
most of the examples use.
|
|
13
|
+
.PP
|
|
14
|
+
Repeat \-\-patch once per patch. They run left to right, each one on the result
|
|
15
|
+
of the last. \-\-input takes a plain ROM, an archive or disc image (the ROM
|
|
16
|
+
inside is found for you), or a rom\-weaver\-bundle.json that already names the
|
|
17
|
+
ROM, the patches, and the output.
|
|
18
|
+
.PP
|
|
19
|
+
The result is compressed by default, into whatever container the \-\-output
|
|
20
|
+
extension names. Pass \-\-no\-compress for a plain ROM file.
|
|
21
|
+
.PP
|
|
22
|
+
Patch formats: IPS, IPS32, SOLID, BPS, UPS, VCDIFF, xdelta, GDIFF,
|
|
23
|
+
HDiffPatch/HPatchZ, APS (N64), APSGBA, RUP, PPF, PAT/FFP, EBP, BDF/BSDIFF40,
|
|
24
|
+
BSP, MOD/PMSR, DLDI, DPS, and DCP (Dreamcast).
|
|
25
|
+
.PP
|
|
26
|
+
Not supported: PDS; NINJA1 (recognized, but cannot be applied); HDiffPatch
|
|
27
|
+
directory patches, HDIFF19 (single\-file .hdiff and .hpatchz are fine).
|
|
28
|
+
.PP
|
|
29
|
+
DCP needs a Dreamcast .cue or .gdi input. It rebuilds the whole disc, so it
|
|
30
|
+
cannot be combined with other patches or with the header and checksum options.
|
|
31
|
+
.SH OPTIONS
|
|
32
|
+
.TP
|
|
33
|
+
\fB\-i\fR, \fB\-\-input\fR \fI<PATH>\fR
|
|
34
|
+
ROM to patch. May be an archive, a disc sheet (.cue/.gdi), or a bundle
|
|
35
|
+
.TP
|
|
36
|
+
\fB\-s\fR, \fB\-\-select\fR \fI<SELECT>\fR
|
|
37
|
+
Pick which file to use when the ROM or a patch is inside an archive, by exact name, prefix, or glob (repeatable)
|
|
38
|
+
.TP
|
|
39
|
+
\fB\-\-target\fR \fI<TARGET>\fR
|
|
40
|
+
For a .cue or .gdi input, which track gets the patch. Matched like \-\-select and must hit exactly one track
|
|
41
|
+
.TP
|
|
42
|
+
\fB\-\-filter\fR \fI<FILTER>\fR
|
|
43
|
+
Consider only files that look like a rom or a patch, judged by extension (repeatable, comma\-separable)
|
|
44
|
+
.br
|
|
45
|
+
|
|
46
|
+
.br
|
|
47
|
+
\fIPossible values:\fR
|
|
48
|
+
.RS 14
|
|
49
|
+
.IP \(bu 2
|
|
50
|
+
rom
|
|
51
|
+
.IP \(bu 2
|
|
52
|
+
patch
|
|
53
|
+
.RE
|
|
54
|
+
.TP
|
|
55
|
+
\fB\-\-no\-extract\fR
|
|
56
|
+
Do not look inside archives; treat the input and every patch as raw files
|
|
57
|
+
.TP
|
|
58
|
+
\fB\-\-no\-ignore\fR
|
|
59
|
+
Also consider files normally skipped inside archives: readmes, images, checksum sidecars, and OS clutter such as .DS_Store
|
|
60
|
+
.TP
|
|
61
|
+
\fB\-\-patch\fR \fI<PATCHES>\fR
|
|
62
|
+
Patch to apply. Repeat once per patch; they run in the order given, each on the
|
|
63
|
+
result of the last.
|
|
64
|
+
|
|
65
|
+
Leave it out and rom\-weaver looks for RetroArch\-style patches sitting next to
|
|
66
|
+
the ROM inside the input archive.
|
|
67
|
+
.TP
|
|
68
|
+
\fB\-o\fR, \fB\-\-output\fR \fI<OUTPUT>\fR
|
|
69
|
+
Where to write the patched ROM. Optional when a bundle already names the output
|
|
70
|
+
.TP
|
|
71
|
+
\fB\-\-bundle\fR \fI<BUNDLE>\fR
|
|
72
|
+
Follow a rom\-weaver\-bundle.json recipe, which lists the patches, their order,
|
|
73
|
+
and the expected checksums. Takes a file path or an http(s) URL.
|
|
74
|
+
|
|
75
|
+
You can usually skip this flag. A bundle is picked up automatically when
|
|
76
|
+
\-\-input is a rom\-weaver\-bundle.json (optionally .gz, .bz2, .xz, or .zst), or an
|
|
77
|
+
archive with one at its root, and you passed no \-\-patch of your own.
|
|
78
|
+
.TP
|
|
79
|
+
\fB\-\-with\fR \fI<GLOB>\fR
|
|
80
|
+
Turn on a bundle patch the bundle leaves off by default, matched by name or file name (repeatable)
|
|
81
|
+
.TP
|
|
82
|
+
\fB\-\-without\fR \fI<GLOB>\fR
|
|
83
|
+
Turn off a bundle patch, matched by name or file name (repeatable)
|
|
84
|
+
.TP
|
|
85
|
+
\fB\-\-no\-compress\fR
|
|
86
|
+
Write a plain ROM instead of compressing the result
|
|
87
|
+
.TP
|
|
88
|
+
\fB\-\-compress\-format\fR \fI<COMPRESS_FORMAT>\fR
|
|
89
|
+
Format to compress the patched ROM into, such as zip, 7z, chd, rvz, or z3ds.
|
|
90
|
+
|
|
91
|
+
Normally you do not need this: the format comes from the \-\-output extension.
|
|
92
|
+
Pass it when the output name has no usable extension. If it disagrees with the
|
|
93
|
+
extension, this flag wins and a warning is printed. Use \-\-no\-compress to write
|
|
94
|
+
a plain ROM instead.
|
|
95
|
+
.TP
|
|
96
|
+
\fB\-\-compress\-codec\fR \fI<COMPRESS_CODEC>\fR
|
|
97
|
+
Compression method for the patched ROM, written as codec or codec:level.
|
|
98
|
+
|
|
99
|
+
Each format has its own codecs, and each picks a sensible one on its own, so
|
|
100
|
+
this is only for overriding that choice. CHD takes a list, tried in order:
|
|
101
|
+
|
|
102
|
+
\-\-compress\-codec cdzs:19,cdzl,cdfl
|
|
103
|
+
|
|
104
|
+
Without :level, a codec follows the \-\-compress\-level profile.
|
|
105
|
+
.TP
|
|
106
|
+
\fB\-\-compress\-level\fR \fI<COMPRESS_LEVEL>\fR
|
|
107
|
+
How hard to compress: min, very\-low, low, medium, high, very\-high, or max [default: max]
|
|
108
|
+
.br
|
|
109
|
+
|
|
110
|
+
.br
|
|
111
|
+
\fIPossible values:\fR
|
|
112
|
+
.RS 14
|
|
113
|
+
.IP \(bu 2
|
|
114
|
+
min
|
|
115
|
+
.IP \(bu 2
|
|
116
|
+
very\-low
|
|
117
|
+
.IP \(bu 2
|
|
118
|
+
low
|
|
119
|
+
.IP \(bu 2
|
|
120
|
+
medium
|
|
121
|
+
.IP \(bu 2
|
|
122
|
+
high
|
|
123
|
+
.IP \(bu 2
|
|
124
|
+
very\-high
|
|
125
|
+
.IP \(bu 2
|
|
126
|
+
max
|
|
127
|
+
.RE
|
|
128
|
+
.TP
|
|
129
|
+
\fB\-\-assume\-in\fR \fI<ALGO=HEX>\fR
|
|
130
|
+
Take this checksum on trust instead of reading the ROM to compute it, as in
|
|
131
|
+
crc32=1234abcd. Repeatable and comma\-separable.
|
|
132
|
+
|
|
133
|
+
This is a speed option for scripts that already know the checksum: it skips a
|
|
134
|
+
full read of a large ROM. It does not verify anything. To check a ROM against a
|
|
135
|
+
checksum, use \-\-expect\-in.
|
|
136
|
+
.TP
|
|
137
|
+
\fB\-\-expect\-in\fR \fI<ALGO=HEX>\fR
|
|
138
|
+
Stop unless the ROM about to be patched has this checksum, as in
|
|
139
|
+
crc32=1234abcd. Repeatable and comma\-separable.
|
|
140
|
+
|
|
141
|
+
Use it when a patch\*(Aqs readme publishes a source checksum, to be sure you are
|
|
142
|
+
starting from the ROM the author used. The size gates size=N and min\-size=N
|
|
143
|
+
work on `patch validate` only.
|
|
144
|
+
.TP
|
|
145
|
+
\fB\-\-patch\-header\fR \fI<PATCH_HEADER>\fR
|
|
146
|
+
Whether a patch applies to the ROM with or without its copier header.
|
|
147
|
+
|
|
148
|
+
Some ROMs carry a small header added by old copier hardware, and a patch may
|
|
149
|
+
have been made either with it or without it. Getting this wrong makes the patch
|
|
150
|
+
fail or produce a broken ROM.
|
|
151
|
+
|
|
152
|
+
auto Work it out per patch (the default). The header is stripped or put
|
|
153
|
+
back only when the patch\*(Aqs own source checksum proves which form it
|
|
154
|
+
expects. With no such proof, the bytes are left alone.
|
|
155
|
+
keep Apply to the bytes as they are.
|
|
156
|
+
strip Remove the header first.
|
|
157
|
+
|
|
158
|
+
Repeatable, and each occurrence binds to the \-\-patch before it and carries
|
|
159
|
+
forward until the next one:
|
|
160
|
+
|
|
161
|
+
\-\-patch a.bps \-\-patch\-header strip \-\-patch b.ups strips for both
|
|
162
|
+
\-\-patch a.bps \-\-patch b.ups \-\-patch\-header strip strips for b.ups only
|
|
163
|
+
|
|
164
|
+
An occurrence before any \-\-patch applies to every patch.
|
|
165
|
+
|
|
166
|
+
Headers detected: A78, LNX, NES, FDS, and SMC signatures, plus the SNES and PCE
|
|
167
|
+
copier size rules.
|
|
168
|
+
.br
|
|
169
|
+
|
|
170
|
+
.br
|
|
171
|
+
\fIPossible values:\fR
|
|
172
|
+
.RS 14
|
|
173
|
+
.IP \(bu 2
|
|
174
|
+
keep
|
|
175
|
+
.IP \(bu 2
|
|
176
|
+
strip
|
|
177
|
+
.IP \(bu 2
|
|
178
|
+
auto
|
|
179
|
+
.RE
|
|
180
|
+
.TP
|
|
181
|
+
\fB\-\-patch\-basis\fR \fI<PATCH_BASIS>\fR
|
|
182
|
+
Which ROM the preceding \-\-patch was built against, and so which one its
|
|
183
|
+
checksums describe.
|
|
184
|
+
|
|
185
|
+
auto Work it out from the checksums (the default).
|
|
186
|
+
base The original ROM. It is verified once up front, and the patch\*(Aqs own
|
|
187
|
+
checks are skipped when it runs later in the chain.
|
|
188
|
+
previous The output of the patch before it.
|
|
189
|
+
|
|
190
|
+
Reach for this when several patches in a chain were each written against the
|
|
191
|
+
unmodified ROM rather than against each other. Binds to the most recent
|
|
192
|
+
\-\-patch.
|
|
193
|
+
.br
|
|
194
|
+
|
|
195
|
+
.br
|
|
196
|
+
\fIPossible values:\fR
|
|
197
|
+
.RS 14
|
|
198
|
+
.IP \(bu 2
|
|
199
|
+
auto
|
|
200
|
+
.IP \(bu 2
|
|
201
|
+
base
|
|
202
|
+
.IP \(bu 2
|
|
203
|
+
previous
|
|
204
|
+
.RE
|
|
205
|
+
.TP
|
|
206
|
+
\fB\-\-output\-header\fR \fI<OUTPUT_HEADER>\fR
|
|
207
|
+
Whether the finished ROM keeps its copier header.
|
|
208
|
+
|
|
209
|
+
auto Keep headers emulators need (iNES, FDS, LNX, A78) and drop the ones
|
|
210
|
+
they do not (SNES, PCE, Game Doctor). The default.
|
|
211
|
+
keep Put back a header that was stripped in order to patch.
|
|
212
|
+
strip Write a headerless ROM, removing the header if it is still there.
|
|
213
|
+
|
|
214
|
+
The chain produces one file, so this is a single setting; if repeated, the last
|
|
215
|
+
value wins.
|
|
216
|
+
|
|
217
|
+
When the header decision changes which extension is conventional, the output
|
|
218
|
+
extension follows (SNES .smc becomes headerless .sfc, for instance) and the
|
|
219
|
+
report says so. Extensions unrelated to headers are never touched.
|
|
220
|
+
.br
|
|
221
|
+
|
|
222
|
+
.br
|
|
223
|
+
\fIPossible values:\fR
|
|
224
|
+
.RS 14
|
|
225
|
+
.IP \(bu 2
|
|
226
|
+
keep
|
|
227
|
+
.IP \(bu 2
|
|
228
|
+
strip
|
|
229
|
+
.IP \(bu 2
|
|
230
|
+
auto
|
|
231
|
+
.RE
|
|
232
|
+
.TP
|
|
233
|
+
\fB\-\-repair\-checksum\fR
|
|
234
|
+
Recompute the ROM\*(Aqs internal header checksum afterwards, so the console does not reject it (SNES, NES, GB, GBA, Mega Drive, SMS, N64, NDS)
|
|
235
|
+
.TP
|
|
236
|
+
\fB\-\-n64\-byte\-order\fR \fI<N64_BYTE_ORDER>\fR
|
|
237
|
+
Byte order to put an N64 ROM in before each patch runs.
|
|
238
|
+
|
|
239
|
+
N64 dumps circulate in three interleavings (.z64 big\-endian, .v64 byte\-swapped,
|
|
240
|
+
\&.n64 little\-endian) and a patch only matches one of them.
|
|
241
|
+
|
|
242
|
+
auto Match whichever order the patch\*(Aqs source CRC32 names. The
|
|
243
|
+
default, and almost always right.
|
|
244
|
+
keep Leave the ROM as it is.
|
|
245
|
+
big\-endian Rewrite to .z64 order.
|
|
246
|
+
little\-endian Rewrite to .n64 order.
|
|
247
|
+
byte\-swapped Rewrite to .v64 order.
|
|
248
|
+
|
|
249
|
+
Repeatable, one per patch; a short list carries its last value forward. The
|
|
250
|
+
output is written back in the order the input arrived in.
|
|
251
|
+
.br
|
|
252
|
+
|
|
253
|
+
.br
|
|
254
|
+
\fIPossible values:\fR
|
|
255
|
+
.RS 14
|
|
256
|
+
.IP \(bu 2
|
|
257
|
+
auto
|
|
258
|
+
.IP \(bu 2
|
|
259
|
+
keep
|
|
260
|
+
.IP \(bu 2
|
|
261
|
+
big\-endian
|
|
262
|
+
.IP \(bu 2
|
|
263
|
+
little\-endian
|
|
264
|
+
.IP \(bu 2
|
|
265
|
+
byte\-swapped
|
|
266
|
+
.RE
|
|
267
|
+
.TP
|
|
268
|
+
\fB\-\-ignore\-checksum\-validation\fR
|
|
269
|
+
Apply the patch even when its own checksums do not match. Can produce a broken ROM
|
|
270
|
+
.TP
|
|
271
|
+
\fB\-\-expect\-out\fR \fI<ALGO=HEX>\fR
|
|
272
|
+
Fail unless the patched ROM has this checksum, as in sha1=abc... (repeatable, comma\-separable)
|
|
273
|
+
.TP
|
|
274
|
+
\fB\-\-code\fR \fI<CODES>\fR
|
|
275
|
+
Game Genie or GameShark/Pro Action Replay code to bake into the ROM. Repeat for each code
|
|
276
|
+
.TP
|
|
277
|
+
\fB\-\-code\-system\fR \fI<CODE_SYSTEM>\fR
|
|
278
|
+
Console the \-\-code values are for (nes, snes, genesis, gameboy), when the ROM header does not say
|
|
279
|
+
.TP
|
|
280
|
+
\fB\-\-code\-kind\fR \fI<CODE_KIND>\fR [default: auto]
|
|
281
|
+
Which cheat scheme the \-\-code values use: auto, game\-genie, or gameshark/par
|
|
282
|
+
.TP
|
|
283
|
+
\fB\-\-emit\-bundle\fR \fI<PATH>\fR
|
|
284
|
+
Also write a rom\-weaver\-bundle.json recording this run, so someone else can repeat it
|
|
285
|
+
.TP
|
|
286
|
+
\fB\-\-tui\fR
|
|
287
|
+
Ask for each patch\*(Aqs name, version, and author, then apply and write a bundle. Needs a terminal
|
|
288
|
+
.TP
|
|
289
|
+
\fB\-j\fR, \fB\-\-threads\fR \fI<auto|N>\fR [default: auto]
|
|
290
|
+
How many threads to use at most. auto uses every core; a format may still use fewer
|
|
291
|
+
.TP
|
|
292
|
+
\fB\-h\fR, \fB\-\-help\fR
|
|
293
|
+
Print help (see a summary with \*(Aq\-h\*(Aq)
|
|
294
|
+
.SH "GLOBAL OPTIONS"
|
|
295
|
+
.TP
|
|
296
|
+
\fB\-\-json\fR
|
|
297
|
+
Print one JSON object per line instead of human\-readable output
|
|
298
|
+
.TP
|
|
299
|
+
\fB\-\-progress\fR
|
|
300
|
+
Show progress even when output is piped to a file or another program
|
|
301
|
+
.TP
|
|
302
|
+
\fB\-\-no\-progress\fR
|
|
303
|
+
Hide progress
|
|
304
|
+
.TP
|
|
305
|
+
\fB\-\-log\-level\fR \fI<LOG_LEVEL>\fR
|
|
306
|
+
How much rom\-weaver logs to stderr. Separate from the normal output [default: off]
|
|
307
|
+
.br
|
|
308
|
+
|
|
309
|
+
.br
|
|
310
|
+
\fIPossible values:\fR
|
|
311
|
+
.RS 14
|
|
312
|
+
.IP \(bu 2
|
|
313
|
+
off
|
|
314
|
+
.IP \(bu 2
|
|
315
|
+
error
|
|
316
|
+
.IP \(bu 2
|
|
317
|
+
warn
|
|
318
|
+
.IP \(bu 2
|
|
319
|
+
info
|
|
320
|
+
.IP \(bu 2
|
|
321
|
+
debug
|
|
322
|
+
.IP \(bu 2
|
|
323
|
+
trace
|
|
324
|
+
.RE
|
|
325
|
+
.TP
|
|
326
|
+
\fB\-v\fR, \fB\-\-verbose\fR
|
|
327
|
+
Log more: \-v for info, \-vv for debug, \-vvv for trace
|
|
328
|
+
.TP
|
|
329
|
+
\fB\-q\fR, \fB\-\-quiet\fR
|
|
330
|
+
Log errors only
|
|
331
|
+
.TP
|
|
332
|
+
\fB\-\-dep\-trace\fR
|
|
333
|
+
Also log trace output from bundled libraries (for bug reports)
|
|
334
|
+
.TP
|
|
335
|
+
\fB\-\-color\fR
|
|
336
|
+
Keep colors even when output is piped
|
|
337
|
+
.TP
|
|
338
|
+
\fB\-\-no\-color\fR
|
|
339
|
+
Turn colors off
|
|
340
|
+
.SH EXTRA
|
|
341
|
+
Examples:
|
|
342
|
+
# One patch, plain ROM out
|
|
343
|
+
rom\-weaver weave \-\-input game.sfc \-\-patch hack.bps \\
|
|
344
|
+
\-\-output hacked.sfc \-\-no\-compress
|
|
345
|
+
|
|
346
|
+
# Two patches in order, straight out of and back into a zip
|
|
347
|
+
rom\-weaver weave \-\-input game.zip \\
|
|
348
|
+
\-\-patch translation.bps \-\-patch fixes.ips \-\-output hacked.zip
|
|
349
|
+
|
|
350
|
+
# Replay someone else\*(Aqs published recipe
|
|
351
|
+
rom\-weaver weave \-\-bundle rom\-weaver\-bundle.json \-\-input game.sfc
|
|
352
|
+
|
|
353
|
+
# Check the result against a checksum the patch author published
|
|
354
|
+
rom\-weaver weave \-\-input game.sfc \-\-patch hack.bps \\
|
|
355
|
+
\-\-output hacked.sfc \-\-no\-compress \\
|
|
356
|
+
\-\-expect\-out sha1=0123456789abcdef0123456789abcdef01234567
|