archive: update format documentation

Mention all formats in the --format section, use backtick quoting for literal values throughout, clarify the description of the configuration option. Helped-by: Junio C Hamano <gitster@pobox.com> Signed-off-by: René Scharfe <l.s.r@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>

René Scharfe committed Jun 15, 2022 at 18:58 UTC 650134a47894244b3804b5d175439b362453fa4a
1 file changed +10 -10
Documentation/git-archive.txt
+10 -10
@@ -34,10 +34,12 @@ OPTIONS
34 -------
35
36 --format=<fmt>::
37 - Format of the resulting archive: 'tar' or 'zip'. If this option
37 + Format of the resulting archive. Possible values are `tar`,
38 + `zip`, `tar.gz`, `tgz`, and any format defined using the
39 + configuration option `tar.<format>.command`. If `--format`
40 is not given, and the output file is specified, the format is
39 - inferred from the filename if possible (e.g. writing to "foo.zip"
40 - makes the output to be in the zip format). Otherwise the output
41 + inferred from the filename if possible (e.g. writing to `foo.zip`
42 + makes the output to be in the `zip` format). Otherwise the output
43 format is `tar`.
44
45 -l::
@@ -143,17 +145,15 @@ tar.<format>.command::
145 is executed using the shell with the generated tar file on its
146 standard input, and should produce the final output on its
147 standard output. Any compression-level options will be passed
146 - to the command (e.g., "-9"). An output file with the same
147 - extension as `<format>` will be use this format if no other
148 - format is given.
148 + to the command (e.g., `-9`).
149 +
150 -The "tar.gz" and "tgz" formats are defined automatically and default to
151 -`gzip -cn`. You may override them with custom commands.
150 +The `tar.gz` and `tgz` formats are defined automatically and use the
151 +command `gzip -cn` by default.
152
153 tar.<format>.remote::
154 - If true, enable `<format>` for use by remote clients via
154 + If true, enable the format for use by remote clients via
155 linkgit:git-upload-archive[1]. Defaults to false for
156 - user-defined formats, but true for the "tar.gz" and "tgz"
156 + user-defined formats, but true for the `tar.gz` and `tgz`
157 formats.
158
159 [[ATTRIBUTES]]