Skip to content

Commit df50034

Browse files
committed
Merge branch 'ja/doc-lint-sections-and-synopsis' into seen
* ja/doc-lint-sections-and-synopsis: fixup! doc: check for absence of multiple terms in each entry of desc list doc lint: check that synopsis manpages have synopsis inlines doc:git-for-each-ref: fix styling and typos doc: check for absence of the form --[no-]parameter doc: check for absence of multiple terms in each entry of desc list doc: check well-formedness of delimited sections doc: test linkgit macros for well-formedness
2 parents 1f1c0e4 + 64fdf14 commit df50034

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+449
-234
lines changed

Documentation/Makefile

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -497,9 +497,26 @@ $(LINT_DOCS_FSCK_MSGIDS): ../fsck.h fsck-msgids.adoc
497497
$(call mkdir_p_parent_template)
498498
$(QUIET_GEN)$(PERL_PATH) lint-fsck-msgids.perl \
499499
../fsck.h fsck-msgids.adoc $@
500-
501500
lint-docs-fsck-msgids: $(LINT_DOCS_FSCK_MSGIDS)
502501

502+
## Lint: delimited sections
503+
LINT_DOCS_DELIMITED_SECTIONS = $(patsubst %.adoc,.build/lint-docs/delimited-sections/%.ok,$(MAN_TXT))
504+
$(LINT_DOCS_DELIMITED_SECTIONS): lint-delimited-sections.perl
505+
$(LINT_DOCS_DELIMITED_SECTIONS): .build/lint-docs/delimited-sections/%.ok: %.adoc
506+
$(call mkdir_p_parent_template)
507+
$(QUIET_LINT_DELIMSEC)$(PERL_PATH) lint-delimited-sections.perl $< >$@
508+
.PHONY: lint-docs-delimited-sections
509+
lint-docs-delimited-sections: $(LINT_DOCS_DELIMITED_SECTIONS)
510+
511+
## Lint: Documentation style
512+
LINT_DOCS_DOC_STYLE = $(patsubst %.adoc,.build/lint-docs/doc-style/%.ok,$(MAN_TXT))
513+
$(LINT_DOCS_DOC_STYLE): lint-documentation-style.perl
514+
$(LINT_DOCS_DOC_STYLE): .build/lint-docs/doc-style/%.ok: %.adoc
515+
$(call mkdir_p_parent_template)
516+
$(QUIET_LINT_DOCSTYLE)$(PERL_PATH) lint-documentation-style.perl $< >$@
517+
.PHONY: lint-docs-doc-style
518+
lint-docs-doc-style: $(LINT_DOCS_DOC_STYLE)
519+
503520
lint-docs-manpages:
504521
$(QUIET_GEN)./lint-manpages.sh
505522

@@ -528,6 +545,8 @@ lint-docs: lint-docs-fsck-msgids
528545
lint-docs: lint-docs-gitlink
529546
lint-docs: lint-docs-man-end-blurb
530547
lint-docs: lint-docs-man-section-order
548+
lint-docs: lint-docs-delimited-sections
549+
lint-docs: lint-docs-doc-style
531550
lint-docs: lint-docs-manpages
532551
lint-docs: lint-docs-meson
533552

Documentation/RelNotes/1.6.2.4.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,3 +37,4 @@ exec >/var/tmp/1
3737
echo O=$(git describe maint)
3838
O=v1.6.2.3-38-g318b847
3939
git shortlog --no-merges $O..maint
40+
---

Documentation/blame-options.adoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,8 @@ include::line-range-format.adoc[]
7575
iso format is used. For supported values, see the discussion
7676
of the --date option at linkgit:git-log[1].
7777

78-
--[no-]progress::
78+
--progress::
79+
--no-progress::
7980
Progress status is reported on the standard error stream
8081
by default when it is attached to a terminal. This flag
8182
enables progress reporting even if not attached to a

Documentation/diff-format.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ if the file was renamed on any side of history. With
103103
followed by the name of the path in the merge commit.
104104

105105
Examples for `-c` and `--cc` without `--combined-all-paths`:
106+
106107
------------------------------------------------
107108
::100644 100644 100644 fabadb8 cc95eb0 4866510 MM desc.c
108109
::100755 100755 100755 52b7a2d 6d1ac04 d2ac7d7 RM bar.sh

Documentation/diff-options.adoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -505,7 +505,8 @@ endif::git-format-patch[]
505505
Turn off rename detection, even when the configuration
506506
file gives the default to do so.
507507

508-
`--[no-]rename-empty`::
508+
`--rename-empty`::
509+
`--no-rename-empty`::
509510
Whether to use empty blobs as rename source.
510511

511512
ifndef::git-format-patch[]

Documentation/fetch-options.adoc

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
--[no-]all::
1+
--all::
2+
--no-all::
23
Fetch all remotes, except for the ones that has the
34
`remote.<name>.skipFetchAll` configuration variable set.
45
This overrides the configuration variable fetch.all`.
@@ -88,7 +89,8 @@ This is incompatible with `--recurse-submodules=[yes|on-demand]` and takes
8889
precedence over the `fetch.output` config option.
8990

9091
ifndef::git-pull[]
91-
--[no-]write-fetch-head::
92+
--write-fetch-head::
93+
--no-write-fetch-head::
9294
Write the list of remote refs fetched in the `FETCH_HEAD`
9395
file directly under `$GIT_DIR`. This is the default.
9496
Passing `--no-write-fetch-head` from the command line tells
@@ -118,13 +120,16 @@ ifndef::git-pull[]
118120
Allow several <repository> and <group> arguments to be
119121
specified. No <refspec>s may be specified.
120122

121-
--[no-]auto-maintenance::
122-
--[no-]auto-gc::
123+
--auto-maintenance::
124+
--no-auto-maintenance::
125+
--auto-gc::
126+
--no-auto-gc::
123127
Run `git maintenance run --auto` at the end to perform automatic
124128
repository maintenance if needed. (`--[no-]auto-gc` is a synonym.)
125129
This is enabled by default.
126130

127-
--[no-]write-commit-graph::
131+
--write-commit-graph::
132+
--no-write-commit-graph::
128133
Write a commit-graph after fetching. This overrides the config
129134
setting `fetch.writeCommitGraph`.
130135
endif::git-pull[]

Documentation/for-each-ref-options.adoc

Lines changed: 41 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -1,84 +1,81 @@
1-
<pattern>...::
2-
If one or more patterns are given, only refs are shown that
3-
match against at least one pattern, either using fnmatch(3) or
1+
`<pattern>...`::
2+
If one or more _<pattern>_ parameters are given, only refs are shown that
3+
match against at least one pattern, either using `fnmatch`(3) or
44
literally, in the latter case matching completely or from the
55
beginning up to a slash.
66

7-
--stdin::
8-
If `--stdin` is supplied, then the list of patterns is read from
9-
standard input instead of from the argument list.
7+
`--stdin`::
8+
The list of patterns is read from standard input instead of from
9+
the argument list.
1010

11-
--count=<count>::
12-
By default the command shows all refs that match
13-
`<pattern>`. This option makes it stop after showing
14-
that many refs.
11+
`--count=<count>`::
12+
Stop after showing _<count>_ refs.
1513

16-
--sort=<key>::
17-
A field name to sort on. Prefix `-` to sort in
14+
`--sort=<key>`::
15+
Sort on the field name _<key>_. Prefix `-` to sort in
1816
descending order of the value. When unspecified,
19-
`refname` is used. You may use the --sort=<key> option
17+
`refname` is used. You may use the `--sort=<key>` option
2018
multiple times, in which case the last key becomes the primary
2119
key.
2220

23-
--format=<format>::
21+
`--format[=<format>]`::
2422
A string that interpolates `%(fieldname)` from a ref being shown and
2523
the object it points at. In addition, the string literal `%%`
2624
renders as `%` and `%xx` - where `xx` are hex digits - renders as
2725
the character with hex code `xx`. For example, `%00` interpolates to
28-
`\0` (NUL), `%09` to `\t` (TAB), and `%0a` to `\n` (LF).
29-
+
30-
When unspecified, `<format>` defaults to `%(objectname) SPC %(objecttype)
26+
`\0` (_NUL_), `%09` to `\t` (_TAB_), and `%0a` to `\n` (_LF_).
27+
28+
When unspecified, _<format>_ defaults to `%(objectname) SPC %(objecttype)
3129
TAB %(refname)`.
3230

33-
--color[=<when>]::
31+
`--color[=<when>]`::
3432
Respect any colors specified in the `--format` option. The
35-
`<when>` field must be one of `always`, `never`, or `auto` (if
33+
_<when__ field must be one of `always`, `never`, or `auto` (if
3634
`<when>` is absent, behave as if `always` was given).
3735

38-
--shell::
39-
--perl::
40-
--python::
41-
--tcl::
36+
`--shell`::
37+
`--perl`::
38+
`--python`::
39+
`--tcl`::
4240
If given, strings that substitute `%(fieldname)`
4341
placeholders are quoted as string literals suitable for
4442
the specified host language. This is meant to produce
45-
a scriptlet that can directly be `eval`ed.
43+
a scriptlet that can directly be "eval"ed.
4644

47-
--points-at=<object>::
45+
`--points-at=<object>`::
4846
Only list refs which points at the given object.
4947

50-
--merged[=<object>]::
48+
`--merged[=<object>]`::
5149
Only list refs whose tips are reachable from the
52-
specified commit (HEAD if not specified).
53-
54-
--no-merged[=<object>]::
55-
Only list refs whose tips are not reachable from the
56-
specified commit (HEAD if not specified).
50+
specified commit (`HEAD` if not specified).
5751

58-
--contains[=<object>]::
59-
Only list refs which contain the specified commit (HEAD if not
52+
`--no-merged[=<object>]`::
53+
Only list refs whose tips are not reachable from _<object>_(`HEAD` if not
6054
specified).
6155

62-
--no-contains[=<object>]::
63-
Only list refs which don't contain the specified commit (HEAD
56+
`--contains[=<object>]`::
57+
Only list refs which contain _<object>_(`HEAD` if not specified).
58+
59+
`--no-contains[=<object>]`::
60+
Only list refs which don't contain _<object>_ (`HEAD`
6461
if not specified).
6562

66-
--ignore-case::
63+
`--ignore-case`::
6764
Sorting and filtering refs are case insensitive.
6865

69-
--omit-empty::
66+
`--omit-empty`::
7067
Do not print a newline after formatted refs where the format expands
7168
to the empty string.
7269

73-
--exclude=<pattern>::
74-
If one or more patterns are given, only refs which do not match
75-
any excluded pattern(s) are shown. Matching is done using the
76-
same rules as `<pattern>` above.
70+
`--exclude=<excluded-pattern>`::
71+
If one or more `--exclude` options are given, only refs which do not
72+
match any _<excluded-pattern>_ parameters are shown. Matching is done
73+
using the same rules as _<pattern>_ above.
7774

78-
--include-root-refs::
79-
List root refs (HEAD and pseudorefs) apart from regular refs.
75+
`--include-root-refs`::
76+
List root refs (`HEAD` and pseudorefs) apart from regular refs.
8077

81-
--start-after=<marker>::
78+
`--start-after=<marker>`::
8279
Allows paginating the output by skipping references up to and including the
8380
specified marker. When paging, it should be noted that references may be
8481
deleted, modified or added between invocations. Output will only yield those

Documentation/git-am.adoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,8 @@ OPTIONS
4848
--keep-non-patch::
4949
Pass `-b` flag to 'git mailinfo' (see linkgit:git-mailinfo[1]).
5050

51-
--[no-]keep-cr::
51+
--keep-cr::
52+
--no-keep-cr::
5253
With `--keep-cr`, call 'git mailsplit' (see linkgit:git-mailsplit[1])
5354
with the same option, to prevent it from stripping CR at the end of
5455
lines. `am.keepcr` configuration variable can be used to specify the

Documentation/git-backfill.adoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,8 @@ OPTIONS
5757
blobs seen at a given path. The default minimum batch size is
5858
50,000.
5959

60-
`--[no-]sparse`::
60+
`--sparse`::
61+
`--no-sparse`::
6162
Only download objects if they appear at a path that matches the
6263
current sparse-checkout. If the sparse-checkout feature is enabled,
6364
then `--sparse` is assumed and can be disabled with `--no-sparse`.

Documentation/git-cat-file.adoc

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,10 @@ OPTIONS
6262
or to ask for a "blob" with `<object>` being a tag object that
6363
points at it.
6464

65-
--[no-]mailmap::
66-
--[no-]use-mailmap::
65+
--mailmap::
66+
--no-mailmap::
67+
--use-mailmap::
68+
--no-use-mailmap::
6769
Use mailmap file to map author, committer and tagger names
6870
and email addresses to canonical real names and email addresses.
6971
See linkgit:git-shortlog[1].

0 commit comments

Comments
 (0)